GNU Octave  6.2.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
octave::tree_decl_elt Class Reference

#include "pt-decl.h"

Collaboration diagram for octave::tree_decl_elt:

Public Types

enum  decl_type { unknown , global , persistent }
 

Public Member Functions

 tree_decl_elt (const tree_decl_elt &)=delete
 
 tree_decl_elt (tree_identifier *i, tree_expression *e=nullptr)
 
 ~tree_decl_elt (void)
 
void accept (tree_walker &tw)
 
tree_decl_eltdup (symbol_scope &scope) const
 
tree_expressionexpression (void)
 
tree_identifierident (void)
 
bool is_global (void) const
 
bool is_persistent (void) const
 
octave_lvalue lvalue (tree_evaluator &tw)
 
bool lvalue_ok (void)
 
void mark_as_formal_parameter (void)
 
void mark_global (void)
 
void mark_persistent (void)
 
std::string name (void) const
 
tree_decl_eltoperator= (const tree_decl_elt &)=delete
 

Private Attributes

tree_expressionm_expr
 
tree_identifierm_id
 
decl_type type
 

Detailed Description

Definition at line 49 of file pt-decl.h.

Member Enumeration Documentation

◆ decl_type

Enumerator
unknown 
global 
persistent 

Definition at line 53 of file pt-decl.h.

Constructor & Destructor Documentation

◆ tree_decl_elt() [1/2]

octave::tree_decl_elt::tree_decl_elt ( tree_identifier i,
tree_expression e = nullptr 
)

Definition at line 47 of file pt-decl.cc.

References error(), and m_id.

Referenced by dup().

◆ tree_decl_elt() [2/2]

octave::tree_decl_elt::tree_decl_elt ( const tree_decl_elt )
delete

◆ ~tree_decl_elt()

octave::tree_decl_elt::~tree_decl_elt ( void  )

Definition at line 54 of file pt-decl.cc.

References m_expr, and m_id.

Member Function Documentation

◆ accept()

◆ dup()

tree_decl_elt * octave::tree_decl_elt::dup ( symbol_scope scope) const

◆ expression()

◆ ident()

◆ is_global()

bool octave::tree_decl_elt::is_global ( void  ) const
inline

Definition at line 83 of file pt-decl.h.

References global, and type.

Referenced by octave::tree_evaluator::visit_decl_elt().

◆ is_persistent()

bool octave::tree_decl_elt::is_persistent ( void  ) const
inline

Definition at line 86 of file pt-decl.h.

References persistent, and type.

Referenced by octave::tree_evaluator::visit_decl_elt().

◆ lvalue()

octave_lvalue octave::tree_decl_elt::lvalue ( tree_evaluator tw)
inline

Definition at line 77 of file pt-decl.h.

References octave::tree_identifier::lvalue(), and m_id.

◆ lvalue_ok()

bool octave::tree_decl_elt::lvalue_ok ( void  )
inline

Definition at line 75 of file pt-decl.h.

References octave::tree_identifier::lvalue_ok(), and m_id.

◆ mark_as_formal_parameter()

void octave::tree_decl_elt::mark_as_formal_parameter ( void  )
inline

◆ mark_global()

void octave::tree_decl_elt::mark_global ( void  )
inline

Definition at line 82 of file pt-decl.h.

References global, and type.

Referenced by octave::tree_decl_init_list::mark_global().

◆ mark_persistent()

void octave::tree_decl_elt::mark_persistent ( void  )
inline

Definition at line 85 of file pt-decl.h.

References persistent, and type.

Referenced by octave::tree_decl_init_list::mark_persistent().

◆ name()

◆ operator=()

tree_decl_elt& octave::tree_decl_elt::operator= ( const tree_decl_elt )
delete

Member Data Documentation

◆ m_expr

tree_expression* octave::tree_decl_elt::m_expr
private

Definition at line 109 of file pt-decl.h.

Referenced by ~tree_decl_elt(), dup(), and expression().

◆ m_id

tree_identifier* octave::tree_decl_elt::m_id
private

◆ type

decl_type octave::tree_decl_elt::type
private

Definition at line 103 of file pt-decl.h.

Referenced by is_global(), is_persistent(), mark_global(), and mark_persistent().


The documentation for this class was generated from the following files: