Class CodeGenerationPreparation
java.lang.Object
org.ek9lang.compiler.CompilerPhase
org.ek9lang.compiler.phase10.CodeGenerationPreparation
- All Implemented Interfaces:
BiFunction<Workspace, CompilerFlags, CompilationPhaseResult>
SINGLE THREADED
Preparation to generate code. What this has to do varies by target architecture.
Always: ensure the '.ek9' directory tree exists, so the generators have somewhere to write.
Then, only for targets whose writer cannot create its own output file, pre-create one empty
file per construct. The JVM target does NOT need this and is skipped - see
targetPreCreatesOutputFiles().
-
Field Summary
Fields inherited from class CompilerPhase
compilableProgramAccess, listener, modelFrozen, reporter -
Constructor Summary
ConstructorsConstructorDescriptionCodeGenerationPreparation(SharedThreadContext<CompilableProgram> compilableProgramAccess, FileHandling fileHandling, Consumer<CompilationEvent> listener, CompilerReporter reporter) -
Method Summary
Modifier and TypeMethodDescriptionbooleandoApply(Workspace workspace, CompilerFlags compilerFlags) Do the compilation phase.Methods inherited from class CompilerPhase
apply, getParsedModuleForSourceMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface BiFunction
andThen
-
Constructor Details
-
Method Details
-
doApply
Description copied from class:CompilerPhaseDo the compilation phase.- Specified by:
doApplyin classCompilerPhase
-