compiler

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 24, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package compiler orchestrates the full schema compilation pipeline: validate → resolve → produce IR.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CompileResult

type CompileResult struct {
	Schema     *ir.Schema
	Validation *validator.ValidationResult
	Errors     []error
}

CompileResult holds the output of the compilation pipeline.

func Compile

func Compile(ds *ast.DocumentSet) *CompileResult

Compile runs the full compilation pipeline: validate → resolve → annotate.

func CompileFile

func CompileFile(filename string, src []byte) *CompileResult

CompileFile compiles a single schema file represented as raw bytes. The filename is used for error reporting only.

func (*CompileResult) HasErrors

func (r *CompileResult) HasErrors() bool

HasErrors returns true when the compilation produced any errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL