|
KSeExpr 6.0.0.0
|
Variable scope builder is used by the type checking and code gen to track visiblity of variables and changing of. More...
#include <ExprEnv.h>
Public Member Functions | |
| ExprVarEnvBuilder () | |
| Creates an empty builder with one current scope entry. | |
| void | reset () |
| Reset to factory state (one empty environment that is current) | |
| ExprVarEnv * | current () |
| Return the current variable scope. | |
| void | setCurrent (ExprVarEnv *env) |
| Set a new current variable scope. | |
| ExprVarEnv * | createDescendant (ExprVarEnv *parent) |
| Create a descendant scope from the provided parent, does not clobber current. | |
Private Attributes | |
| std::vector< std::unique_ptr< ExprVarEnv > > | all |
| All owned symbol tables. | |
| ExprVarEnv * | _currentEnv {nullptr} |
| The current symbol table (should be a pointer owned by all) | |
Variable scope builder is used by the type checking and code gen to track visiblity of variables and changing of.
|
inline |
|
inline |
|
inline |
Return the current variable scope.
Definition at line 196 of file ExprEnv.h.
References _currentEnv.
|
inline |
Reset to factory state (one empty environment that is current)
Definition at line 189 of file ExprEnv.h.
References _currentEnv, and all.
Referenced by ExprVarEnvBuilder(), and KSeExpr::Expression::reset().
|
inline |
|
private |
The current symbol table (should be a pointer owned by all)
Definition at line 218 of file ExprEnv.h.
Referenced by current(), reset(), and setCurrent().
|
private |
All owned symbol tables.
Definition at line 216 of file ExprEnv.h.
Referenced by createDescendant(), and reset().