26 #if defined (HAVE_CONFIG_H)
81 && t_parent->look_nonlocal (
name, offset, ret))
97 std::list<octave_value>
retval;
135 std::map<std::string, octave_value>
m
149 std::map<std::string, octave_value> info_map;
153 std::string nm = nm_sr.first;
155 info_map[nm] = sr.
dump ();
163 std::list<symbol_record>
retval;
166 retval.push_back (nm_sr.second);
182 return t_parent->find_subfunction (
name);
202 m_parent = std::weak_ptr<symbol_scope_rep> (parent);
232 if (t_parent == scope)
238 if (t_primary_parent)
242 if (t_primary_parent == scope)
247 auto scope_primary_parent = scope->primary_parent_scope_rep ();
248 if (t_primary_parent == scope_primary_parent)
270 t_parent->look_nonlocal (nm_sr.first, offset, ours);
288 scope_obj.cache_parent_fcn_names (plst);
289 scope_obj.update_nest ();
305 return t_parent->look_nonlocal (
name, offset, result);
315 size_t t_frame_offset = offset + p->second.frame_offset ();
316 size_t t_data_offset = p->second.data_offset ();
330 return std::list<octave_value> ();
333 return m_rep->localfunctions ();
335 std::shared_ptr<symbol_scope_rep> ppsr
336 =
m_rep->primary_parent_scope_rep ();
339 return std::list<octave_value> ();
341 return ppsr->localfunctions ();
void set_data_offset(size_t offset)
void mark_added_static(void)
void set_frame_offset(size_t offset)
bool is_formal(void) const
octave_value dump(void) const
std::string name(void) const
std::weak_ptr< symbol_scope_rep > m_primary_parent
Primary (top) parent of nested function (may be null).
std::string m_name
Name for this scope (usually the corresponding filename of the function corresponding to the scope).
std::vector< symbol_scope > m_children
Child nested functions.
std::string name(void) const
std::map< std::string, symbol_record >::iterator table_iterator
std::string m_dir_name
The directory associated with m_code.
std::map< std::string, octave_value >::const_iterator subfunctions_const_iterator
std::map< std::string, octave_value > m_subfunctions
Map from symbol names to subfunctions.
bool is_relative(const std::shared_ptr< symbol_scope_rep > &scope) const
octave_value dump(void) const
size_t m_nesting_depth
If true, then this scope belongs to a nested function.
void set_parent(const std::shared_ptr< symbol_scope_rep > &parent)
std::map< std::string, symbol_record > m_symbols
Map from symbol names to symbol info.
symbol_record insert_local(const std::string &name)
void mark_subfunctions_in_scope_as_private(const std::string &class_name)
std::string m_fcn_name
Simple name of the function corresponding to this scope.
bool look_nonlocal(const std::string &name, size_t offset, symbol_record &result)
octave_value dump_symbols_map(void) const
size_t num_symbols(void) const
std::list< std::string > m_subfunction_names
The list of subfunctions (if any) in the order they appear in the function file.
symbol_record insert(const std::string &name)
octave_value find_subfunction(const std::string &name) const
std::list< octave_value > localfunctions(void) const
bool m_is_static
If true then no variables can be added.
std::weak_ptr< symbol_scope_rep > m_parent
Parent of nested function (may be null).
bool is_nested(void) const
void set_primary_parent(const std::shared_ptr< symbol_scope_rep > &parent)
void insert_symbol_record(symbol_record &sr)
std::list< std::string > parent_fcn_names(void) const
void cache_dir_name(const std::string &name)
std::list< symbol_record > symbol_list(void) const
std::shared_ptr< symbol_scope_rep > m_rep
std::list< std::string > parent_fcn_names(void) const
bool is_primary_fcn_scope(void) const
std::list< octave_value > localfunctions(void) const
virtual octave_function * function_value(bool silent=false)
virtual void mark_as_private_function(const std::string &cname="")
octave::symbol_scope scope(void)
octave_user_code * user_code_value(bool silent=false) const
std::string canonicalize_file_name(const std::string &name)
octave_value dump_function_map(const std::map< std::string, octave_value > &fcn_map)
return octave_value(v1.char_array_value() . concat(v2.char_array_value(), ra_idx),((a1.is_sq_string()||a2.is_sq_string()) ? '\'' :'"'))
octave_value::octave_value(const Array< char > &chm, char type) return retval