Class CodeGenerationConstants

java.lang.Object
org.ek9lang.compiler.CompilerPhase
org.ek9lang.compiler.phase10.CodeGenerationConstants
All Implemented Interfaces:
BiFunction<Workspace, CompilerFlags, CompilationPhaseResult>

public class CodeGenerationConstants extends CompilerPhase
MULTI THREADED Generate all constants that have been defined.

Aggregates all constant IRConstructs per module into a single _Constants JVM class. Each module's constants become static fields on the generated class, initialized in <clinit>.

This phase runs BEFORE CodeGenerationAggregates (Phase 14) because programs and classes may reference constants. With ASM's COMPUTE_FRAMES, referenced classes must exist on disk.