The StaDyn Programming Language
Source code documentation of StaDyn, a hybrid static and dynamic typing language.
|
Implementation of a table of constants. More...
Public Member Functions | |
ConstantTable () | |
Constructor of ConstantTable. More... | |
void | Set () |
Add a new scope More... | |
void | Reset () |
Removes the last scope More... | |
bool | Insert (string id, Expression init) |
Insert a new constant in the current scope. More... | |
Expression | Search (string id, out int scope) |
Searches the initialization of constant identifier. More... | |
Expression | Search (string id) |
Searches the initialization of constant identifier. It performs a full search. More... | |
ConstantTable () | |
Constructor of ConstantTable. More... | |
void | Set () |
Add a new scope More... | |
void | Reset () |
Removes the last scope More... | |
bool | Insert (string id, Expression init) |
Insert a new constant in the current scope. More... | |
Expression | Search (string id, out int scope) |
Searches the initialization of constant identifier. More... | |
Expression | Search (string id) |
Searches the initialization of constant identifier. It performs a full search. More... | |
Implementation of a table of constants.
Definition at line 27 of file ConstantTable.cs.
CodeGeneration.ConstantTable.ConstantTable | ( | ) |
Constructor of ConstantTable.
Definition at line 42 of file ConstantTable.cs.
CodeGeneration.ConstantTable.ConstantTable | ( | ) |
Constructor of ConstantTable.
Definition at line 42 of file ConstantTable.cs.
bool CodeGeneration.ConstantTable.Insert | ( | string | id, |
Expression | init | ||
) |
Insert a new constant in the current scope.
id | Constant identifier. |
init | Constant initialization. |
Definition at line 78 of file ConstantTable.cs.
bool CodeGeneration.ConstantTable.Insert | ( | string | id, |
Expression | init | ||
) |
Insert a new constant in the current scope.
id | Constant identifier. |
init | Constant initialization. |
Definition at line 78 of file ConstantTable.cs.
void CodeGeneration.ConstantTable.Reset | ( | ) |
Removes the last scope
Definition at line 64 of file ConstantTable.cs.
void CodeGeneration.ConstantTable.Reset | ( | ) |
Removes the last scope
Definition at line 64 of file ConstantTable.cs.
Expression CodeGeneration.ConstantTable.Search | ( | string | id, |
out int | scope | ||
) |
Searches the initialization of constant identifier.
id | Identifier name. |
scope | zero-based scope where the constant is found. -1 if the search does not success |
// devolver un scope
Definition at line 96 of file ConstantTable.cs.
Expression CodeGeneration.ConstantTable.Search | ( | string | id, |
out int | scope | ||
) |
Searches the initialization of constant identifier.
id | Identifier name. |
scope | zero-based scope where the constant is found. -1 if the search does not success |
// devolver un scope
Definition at line 96 of file ConstantTable.cs.
Expression CodeGeneration.ConstantTable.Search | ( | string | id | ) |
Searches the initialization of constant identifier. It performs a full search.
id | Identifier name. |
// devolver un scope
Definition at line 113 of file ConstantTable.cs.
Expression CodeGeneration.ConstantTable.Search | ( | string | id | ) |
Searches the initialization of constant identifier. It performs a full search.
id | Identifier name. |
// devolver un scope
Definition at line 113 of file ConstantTable.cs.
void CodeGeneration.ConstantTable.Set | ( | ) |
Add a new scope
Definition at line 53 of file ConstantTable.cs.
void CodeGeneration.ConstantTable.Set | ( | ) |
Add a new scope
Definition at line 53 of file ConstantTable.cs.