 |
User Guide
|
Go to the documentation of this file.
46 std::shared_ptr<ModToken>
token;
110 return "UnaryExpression";
118 return std::static_pointer_cast<UnaryExpression>(shared_from_this());
125 return std::static_pointer_cast<const UnaryExpression>(shared_from_this());
Abstract base class for all constant visitors implementation.
std::shared_ptr< ModToken > token
token with location information
std::shared_ptr< Expression > get_expression() const noexcept
Getter for member variable UnaryExpression::expression.
void set_token(const ModToken &tok)
Set token for the current ast node.
THIS FILE IS GENERATED AT BUILD TIME AND SHALL NOT BE EDITED.
Abstract Syntax Tree (AST) related implementations.
void set_expression(std::shared_ptr< Expression > &&expression)
Setter for member variable UnaryExpression::expression (rvalue reference)
AstNodeType
Enum type for every AST node type.
std::shared_ptr< const Ast > get_shared_ptr() const override
Get std::shared_ptr from this pointer of the current ast node.
void accept(visitor::Visitor &v) override
accept (or visit) the current AST node using provided visitor
Abstract base class for all visitors implementation.
void visit_children(visitor::Visitor &v) override
visit children i.e.
std::string get_node_type_name() const noexcept override
Return type (ast::AstNodeType) of ast node as std::string.
Auto generated AST classes declaration.
const ModToken * get_token() const noexcept override
Return associated token for the current ast node.
virtual ~UnaryExpression()=default
const UnaryOperator & get_op() const noexcept
Getter for member variable UnaryExpression::op.
std::shared_ptr< Ast > get_shared_ptr() override
Get std::shared_ptr from this pointer of the current ast node.
AstNodeType get_node_type() const noexcept override
Return type (ast::AstNodeType) of ast node.
void set_op(UnaryOperator &&op)
Setter for member variable UnaryExpression::op (rvalue reference)
std::shared_ptr< Expression > expression
TODO.
UnaryExpression(const UnaryOperator &op, Expression *expression)
@ UNARY_EXPRESSION
type of ast::UnaryExpression
bool is_unary_expression() const noexcept override
Check if the ast node is an instance of ast::UnaryExpression.
UnaryExpression * clone() const override
Return a copy of the current node.
Auto generated AST classes declaration.
Base class for all expressions in the NMODL.
void set_parent_in_children()
Set this object as parent for all the children.
Represent token returned by scanner.