KiCad PCB EDA Suite
Loading...
Searching...
No Matches
LIBEVAL Namespace Reference

Classes

class  COMPILER
 
class  CONTEXT
 
struct  ERROR_STATUS
 
struct  T_TOKEN
 
struct  T_TOKEN_VALUE
 
class  TOKENIZER
 
class  TREE_NODE
 
class  UCODE
 
class  UNIT_RESOLVER
 
class  UOP
 
class  VALUE
 
class  VAR_REF
 

Typedefs

typedef std::function< void(CONTEXT *, void *)> FUNC_CALL_REF
 

Enumerations

enum  COMPILATION_STAGE { CST_PARSE = 0 , CST_CODEGEN , CST_RUNTIME }
 
enum  VAR_TYPE_T { VT_STRING = 1 , VT_NUMERIC , VT_UNDEFINED , VT_PARSE_ERROR }
 
enum  TOKEN_TYPE_T {
  TR_UNDEFINED = 0 , TR_NUMBER = 1 , TR_IDENTIFIER = 2 , TR_ASSIGN = 3 ,
  TR_STRUCT_REF = 4 , TR_STRING = 5 , TR_UNIT = 6 , TR_ARG_LIST = 7 ,
  TR_NULL = 8
}
 

Functions

TREE_NODEnewNode (LIBEVAL::COMPILER *compiler, int op, const T_TOKEN_VALUE &value)
 
static const wxString formatOpName (int op)
 
const wxString formatNode (TREE_NODE *node)
 
void dumpNode (wxString &buf, TREE_NODE *tok, int depth=0)
 
static void prepareTree (LIBEVAL::TREE_NODE *node)
 
static std::vector< TREE_NODE * > squashParamList (TREE_NODE *root)
 

Variables

constexpr T_TOKEN_VALUE defaultTokenValue = { nullptr, 0.0, 0 }
 
constexpr T_TOKEN defaultToken = { TR_UNDEFINED, defaultTokenValue }
 

Typedef Documentation

◆ FUNC_CALL_REF

typedef std::function<void( CONTEXT*, void* )> LIBEVAL::FUNC_CALL_REF

Definition at line 109 of file libeval_compiler.h.

Enumeration Type Documentation

◆ COMPILATION_STAGE

Enumerator
CST_PARSE 
CST_CODEGEN 
CST_RUNTIME 

Definition at line 66 of file libeval_compiler.h.

◆ TOKEN_TYPE_T

Enumerator
TR_UNDEFINED 
TR_NUMBER 
TR_IDENTIFIER 
TR_ASSIGN 
TR_STRUCT_REF 
TR_STRING 
TR_UNIT 
TR_ARG_LIST 
TR_NULL 

Definition at line 91 of file libeval_compiler.h.

◆ VAR_TYPE_T

Enumerator
VT_STRING 
VT_NUMERIC 
VT_UNDEFINED 
VT_PARSE_ERROR 

Definition at line 83 of file libeval_compiler.h.

Function Documentation

◆ dumpNode()

◆ formatNode()

const wxString LIBEVAL::formatNode ( TREE_NODE node)

◆ formatOpName()

static const wxString LIBEVAL::formatOpName ( int  op)
static

◆ newNode()

◆ prepareTree()

static void LIBEVAL::prepareTree ( LIBEVAL::TREE_NODE node)
static

◆ squashParamList()

static std::vector< TREE_NODE * > LIBEVAL::squashParamList ( TREE_NODE root)
static

Variable Documentation

◆ defaultToken

constexpr T_TOKEN LIBEVAL::defaultToken = { TR_UNDEFINED, defaultTokenValue }
constexpr

Definition at line 129 of file libeval_compiler.h.

Referenced by LIBEVAL::COMPILER::Compile().

◆ defaultTokenValue

constexpr T_TOKEN_VALUE LIBEVAL::defaultTokenValue = { nullptr, 0.0, 0 }
constexpr

Definition at line 119 of file libeval_compiler.h.

Referenced by LIBEVAL::COMPILER::getToken().