Module com.darkcollective.relix.semantic
module com.darkcollective.relix.semantic
Semantic analysis for
.relix scripting language source files.
This module takes a parsed Script
(produced by relix-lang) and performs:
- Import resolution — loads all transitively imported files, detects cycles, and determines a safe processing order.
- Symbol collection — registers every source declaration,
assignment, and
defstatement as a typed symbol in the symbol table. - Schema inference — walks each relational algebra expression body and infers the output schema at every node.
- Validation — checks name resolution, function arities, schema compatibility for set operations, and source config completeness.
The entry point is SemanticAnalyzer,
whose contract is Script → SemanticResult — the engine
analyses an AST, and the concrete .relix text syntax is one frontend
that produces one. Where a Script comes from is pluggable behind
ScriptLoader; the grammar itself is
not on this module's main classpath, so reading text —
Relix.parse, FileSystemScriptLoader — lives in
the front ends (Decision 2).
Built-in functions and relations are registered via a
BuiltinProvider hook passed at
construction time.
Analysis always returns a
SemanticResult that carries both a
(possibly partial) SemanticModel and
any SemanticErrors collected during
analysis.
-
Packages
ExportsPackageDescriptionThe result of analysing a script, and the seams analysis reads through.Join-path resolution over the schema graph.Indirect ExportsFromPackagescom.darkcollective.relix.lang.ast com.darkcollective.relix.lang.ast.source com.darkcollective.relix.lang.ast.table -
Modules
RequiresModifierModuleDescriptiontransitiveCost estimation for relix relational algebra trees.transitiveObservability events for the relix query pipeline.transitiveThe function SPI: the description of a scalar function or aggregate that the engine reasons about, and the seam through which an implementation is supplied.transitiveAST node types for the relix scripting language.transitiveSymbol table, type system, and relation/function symbol hierarchy for the relix system.Indirect RequiresModifierModuleDescriptiontransitiveRelational algebra AST — immutable node types, predicates, operands, and visitor infrastructure for traversal and transformation.transitiveThe sealedValuehierarchy — the scalar values a query produces and consumes.