Interpreter prototype alpha
c++ interpreter for make believe language
 
Loading...
Searching...
No Matches
NumberNode Class Reference

creates a node in the syntax tree of type NumberNode More...

#include <NumberNode.h>

Inheritance diagram for NumberNode:
tokenNode

Public Member Functions

 NumberNode ()
 constructor
 
std::string __represent__ ()
 (virtual) returns a string representing the current state of this NumberNode and it's syntax tree structure
 
- Public Member Functions inherited from tokenNode
 tokenNode ()
 constructor
 
virtual std::string __represent__ ()=0
 (virtual) returns a string representing the current state of the syntax tree
 

Public Attributes

bool isUnaryOperator = false
 is used for testing if this node is a unary operator node eg: -5
 
std::string unary_op_token = ""
 symbol of the unary operator
 
std::shared_ptr< tokenNodeunaryopdata = nullptr
 pointer to the unary operator data eg the 5 in -(5)
 
double value = 0.0
 holds the value(int or double) of this node
 
- Public Attributes inherited from tokenNode
std::string nodeType = "None"
 used for directing execution in the syntax tree
 

Detailed Description

creates a node in the syntax tree of type NumberNode

Author
Michael

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