![Logo](logo.png) |
User Guide
|
Go to the documentation of this file.
44 std::shared_ptr<ModToken>
token;
129 return std::static_pointer_cast<Global>(shared_from_this());
136 return std::static_pointer_cast<const Global>(shared_from_this());
165 GlobalVarVector::const_iterator
erase_global_var(GlobalVarVector::const_iterator first);
170 GlobalVarVector::const_iterator
erase_global_var(GlobalVarVector::const_iterator first, GlobalVarVector::const_iterator last);
182 GlobalVarVector::const_iterator
insert_global_var(GlobalVarVector::const_iterator position,
const std::shared_ptr<GlobalVar>& n);
187 template <
class NodeType,
class InputIterator>
188 void insert_global_var(GlobalVarVector::const_iterator position, NodeType& to, InputIterator first, InputIterator last);
198 void reset_global_var(GlobalVarVector::const_iterator position, std::shared_ptr<GlobalVar> n);
291 template <
class NodeType,
class InputIterator>
294 for (
auto it = first; it != last; ++it) {
Abstract base class for all constant visitors implementation.
void accept(visitor::Visitor &v) override
accept (or visit) the current AST node using provided visitor
std::string get_nmodl_name() const noexcept override
Return NMODL statement of ast node as std::string.
std::shared_ptr< const Ast > get_shared_ptr() const override
Get std::shared_ptr from this pointer of the current ast node.
const ModToken * get_token() const noexcept override
Return associated token for the current ast node.
THIS FILE IS GENERATED AT BUILD TIME AND SHALL NOT BE EDITED.
GlobalVarVector::const_iterator erase_global_var(GlobalVarVector::const_iterator first)
Erase member to variables.
bool is_global() const noexcept override
Check if the ast node is an instance of ast::Global.
Abstract Syntax Tree (AST) related implementations.
const GlobalVarVector & get_variables() const noexcept
Getter for member variable Global::variables.
void reset_global_var(GlobalVarVector::const_iterator position, GlobalVar *n)
Reset member to variables.
std::vector< std::shared_ptr< GlobalVar > > GlobalVarVector
AstNodeType
Enum type for every AST node type.
AstNodeType get_node_type() const noexcept override
Return type (ast::AstNodeType) of ast node.
Auto generated AST classes declaration.
std::shared_ptr< ModToken > token
token with location information
Global(const GlobalVarVector &variables)
Abstract base class for all visitors implementation.
Global * clone() const override
Return a copy of the current node.
Auto generated AST classes declaration.
Represents GLOBAL statement in NMODL.
GlobalVarVector variables
Vector of global variables.
@ GLOBAL
type of ast::Global
void set_parent_in_children()
Set this object as parent for all the children.
std::string get_node_type_name() const noexcept override
Return type (ast::AstNodeType) of ast node as std::string.
void visit_children(visitor::Visitor &v) override
visit children i.e.
void set_token(const ModToken &tok)
Set token for the current ast node.
virtual ~Global()=default
void set_variables(GlobalVarVector &&variables)
Setter for member variable Global::variables (rvalue reference)
void emplace_back_global_var(GlobalVar *n)
Add member to variables by raw pointer.
Represent token returned by scanner.
GlobalVarVector::const_iterator insert_global_var(GlobalVarVector::const_iterator position, const std::shared_ptr< GlobalVar > &n)
Insert member to variables.
std::shared_ptr< Ast > get_shared_ptr() override
Get std::shared_ptr from this pointer of the current ast node.