Class VariableDeclarationInstructionCreator
java.lang.Object
org.ek9lang.compiler.phase7.VariableDeclarationInstructionCreator
Creates IR instructions for variable declarations.
Generates new BasicBlock IR (IRInstructions) instead of old Block IR (INode).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapply
(EK9Parser.VariableDeclarationContext ctx, String scopeId) Generate IR instructions for variable declaration with assignment.applyVariableOnly
(EK9Parser.VariableOnlyDeclarationContext ctx, String scopeId) Generate IR instructions for variable only declaration.
-
Constructor Details
-
VariableDeclarationInstructionCreator
-
-
Method Details
-
apply
Generate IR instructions for variable declaration with assignment. Example: stdout <- Stdout() -
applyVariableOnly
public List<IRInstruction> applyVariableOnly(EK9Parser.VariableOnlyDeclarationContext ctx, String scopeId) Generate IR instructions for variable only declaration. Example: var stdout Stdout
-