Class: ScopeDeclaration
compiler.ScopeDeclaration
An symbol table entry of a variable, parameter or function declaration inside a Kipper scope.
Abstract base class for ScopeVariableDeclaration, ScopeParameterDeclaration and ScopeFunctionDeclaration. This is used like an entry for a symbol table, where the important information about a variable, parameter or function is stored.
Since
0.1.2
Hierarchy
ScopeDeclaration
Table of contents
Constructors
Accessors
Constructors
constructor
• new ScopeDeclaration()
Accessors
hasValue
• Abstract
get
hasValue(): boolean
Returns whether the declaration has a value.
Since
0.10.0
Returns
boolean
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:45
identifier
• Abstract
get
identifier(): string
Returns
string
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:20
isCallable
• Abstract
get
isCallable(): boolean
Returns whether the declaration has a callable value (function).
Since
0.10.0
Returns
boolean
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:51
isDefined
• Abstract
get
isDefined(): boolean
Returns whether the scope declaration was defined during its declaration.
Since
0.10.0
Returns
boolean
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:39
node
• Abstract
get
node(): Declaration
<DeclarationSemantics
, DeclarationTypeSemantics
>
Returns
Declaration
<DeclarationSemantics
, DeclarationTypeSemantics
>
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:18
programCtx
• get
programCtx(): KipperProgramContext
Fetches the program context instance for this token.
Returns
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:25
type
• Abstract
get
type(): CheckedType
The value type of this declaration.
Since
0.10.0
Returns
Defined in
kipper/core/src/compiler/analysis/symbol-table/entry/scope-declaration.ts:33