Mercurial > octave
changeset 24386:a164fd6e7e7b
eliminate unused symbol_record member variable and related functions
* symrec.h (symbol_record::m_valid): Delete variable and all uses.
(symbol_record::symbol_record_rep::is_valid,
symbol_record::symbol_record_rep::invalidate,
symbol_record::is_valid, symbol_record::invalidate): Delete.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 07 Dec 2017 15:40:43 -0500 |
parents | c7f56bffe02f |
children | 268d31e7aa4f |
files | libinterp/corefcn/symrec.h |
diffstat | 1 files changed, 1 insertions(+), 29 deletions(-) [+] |
line wrap: on
line diff
--- a/libinterp/corefcn/symrec.h Thu Dec 07 10:33:21 2017 -0800 +++ b/libinterp/corefcn/symrec.h Thu Dec 07 15:40:43 2017 -0500 @@ -81,7 +81,7 @@ symbol_record_rep (const std::string& nm, const octave_value& v, unsigned int sc) : m_storage_class (sc), m_name (nm), m_fwd_scope (nullptr), - m_fwd_rep (), m_value_stack (), m_valid (true) + m_fwd_rep (), m_value_stack () { m_value_stack.push_back (v); } @@ -231,14 +231,6 @@ return varval (context).is_defined (); } - bool is_valid (void) const - { - if (auto t_fwd_rep = m_fwd_rep.lock ()) - return t_fwd_rep->is_valid (); - - return m_valid; - } - bool is_variable (context_id context) const { if (auto t_fwd_rep = m_fwd_rep.lock ()) @@ -481,17 +473,6 @@ void init_persistent (void); - void invalidate (void) - { - if (auto t_fwd_rep = m_fwd_rep.lock ()) - { - t_fwd_rep->invalidate (); - return; - } - - m_valid = false; - } - void bind_fwd_rep (symbol_scope_rep *fwd_scope, const std::shared_ptr<symbol_record_rep>& fwd_rep) { @@ -524,8 +505,6 @@ std::weak_ptr<symbol_record_rep> m_fwd_rep; std::deque<octave_value> m_value_stack; - - bool m_valid; }; public: @@ -608,11 +587,6 @@ return ! m_rep->is_defined (context); } - bool is_valid (void) const - { - return m_rep->is_valid (); - } - bool is_variable (context_id context) const { return m_rep->is_variable (context); @@ -646,8 +620,6 @@ void init_persistent (void) { m_rep->init_persistent (); } - void invalidate (void) { m_rep->invalidate (); } - unsigned int storage_class (void) const { return m_rep->storage_class (); } void bind_fwd_rep (symbol_scope_rep *fwd_scope, const symbol_record& sr)