mirror of https://github.com/tbklang/tlang.git
Added plumbing for code generation
This commit is contained in:
parent
d34dd5b689
commit
274ea767a2
|
@ -0,0 +1,32 @@
|
|||
module compiler.codegen.core;
|
||||
|
||||
import compiler.symbols.data;
|
||||
|
||||
/**
|
||||
* TODO: Perhaps have an interface that can emit(Context/Parent, Statement)
|
||||
*/
|
||||
|
||||
/* TODO: Module linking (general overhaul required) */
|
||||
|
||||
public class CodeGenerator
|
||||
{
|
||||
/* The Module */
|
||||
Module modulle;
|
||||
|
||||
this(Module modulle)
|
||||
{
|
||||
this.modulle = modulle;
|
||||
}
|
||||
}
|
||||
|
||||
public import compiler.codegen.dgen;
|
||||
|
||||
/**
|
||||
* Emittable
|
||||
*
|
||||
* All structures that can emit code go under here
|
||||
*/
|
||||
public interface Emittable
|
||||
{
|
||||
public string emit();
|
||||
}
|
Loading…
Reference in New Issue