diff options
author | Carl Worth <cworth@cworth.org> | 2010-06-23 16:27:18 -0700 |
---|---|---|
committer | Carl Worth <cworth@cworth.org> | 2010-06-23 16:38:05 -0700 |
commit | 015b3a5115df9a53b73d4b99fed86cf245c87aca (patch) | |
tree | a1706731b6508e2d8a1d56711d86a6c72b2b1928 /s_expression.cpp | |
parent | f961e4458f1e894ca782c1627b69cdee993a16f8 (diff) |
exec_node: Remove destructor from exec_node and all descendants.
Two of these destructors are non-empty, (s_symbol and s_list), so this
commit could potentially introduce memory leaks, (though, no additional
leaks are found in glsl-orangebook-ch06-bump.frag at least---perhaps
the current code is never calling delete on these classes?).
Going forward, we will switch to talloc for exec_node so we won't need
explicit destrcutors to free up any memory used.
Diffstat (limited to 's_expression.cpp')
-rw-r--r-- | s_expression.cpp | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/s_expression.cpp b/s_expression.cpp index 4022dfab7a..0fb296ef67 100644 --- a/s_expression.cpp +++ b/s_expression.cpp @@ -34,25 +34,10 @@ s_symbol::s_symbol(const char *tmp) strcpy(this->str, tmp); } -s_symbol::~s_symbol() -{ - delete [] this->str; - this->str = NULL; -} - s_list::s_list() { } -s_list::~s_list() -{ - exec_list_iterator it(this->subexpressions.iterator()); - while (it.has_next()) - it.remove(); - - assert(this->subexpressions.is_empty()); -} - unsigned s_list::length() const { |