caffeine_lang/compiler
Types
Output of the compilation process containing Terraform, optional dependency graph, and warnings.
pub type CompilationOutput {
CompilationOutput(
terraform: String,
dependency_graph: option.Option(String),
warnings: List(String),
)
}
Constructors
-
CompilationOutput( terraform: String, dependency_graph: option.Option(String), warnings: List(String), )
Values
pub fn compile(
blueprint: source_file.SourceFile(source_file.BlueprintSource),
expectations: List(
source_file.SourceFile(source_file.ExpectationSource),
),
) -> Result(CompilationOutput, errors.CompilationError)
Compiles a blueprint and expectation sources into Terraform configuration. Pure function — all file reading happens before this function is called.
pub fn compile_from_strings(
blueprints_source: String,
expectations_source: String,
expectations_path: String,
) -> Result(CompilationOutput, errors.CompilationError)
Compiles from source strings directly (no file I/O). Used for browser-based compilation.