tcalc 0.2.0
 
Loading...
Searching...
No Matches
tcalc::ast::Node Class Reference

Base class for AST nodes. More...

#include <node.hpp>

Inheritance diagram for tcalc::ast::Node:
tcalc::ast::BinaryOpNode tcalc::ast::FcallNode tcalc::ast::FdefNode tcalc::ast::IfNode tcalc::ast::NumberNode tcalc::ast::ProgramImportNode tcalc::ast::ProgramNode tcalc::ast::UnaryOpNode tcalc::ast::VarAssignNode tcalc::ast::VarRefNode

Public Member Functions

 Node (NodeType type)
 Construct a new Node object.
 
TCALC_INLINE auto type () const noexcept
 Get the node type.
 

Detailed Description

Base class for AST nodes.

Constructor & Destructor Documentation

◆ Node()

tcalc::ast::Node::Node ( NodeType  type)
inlineexplicit

Construct a new Node object.

Parameters
typeNode type.

Member Function Documentation

◆ type()

TCALC_INLINE auto tcalc::ast::Node::type ( ) const
inlinenoexcept

Get the node type.

Returns
NodeType Node type.

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