Expand description
Lossless concrete syntax for Fable.
Fable is the tiny typed language intended to inspect and mutate
Facet-reflected Rust values, then lower toward canonical Weavy IR. This crate
owns the lossless lexer/parser plus the first typed lowering and interpreter
surfaces for in-place scripts and in to out transforms.
Modules§
- ast
- Typed views over the Fable CST.
Structs§
- Fable
Field - Read-only handle passed to field-aware Fable host intrinsics.
- Fable
Field Mut - Mutable handle passed to field-aware Fable host intrinsics.
- Fable
Intrinsics - Host-call registry used while lowering Fable calls.
- Fable
Plan - A reusable lowered Fable program for
T. - Fable
Predicate Plan - A reusable lowered Fable predicate for
T. - Fable
Query Plan - A reusable lowered Fable query for
T. - Fable
Root Plan - A reusable lowered Fable program over explicitly named roots.
- Fable
Root Predicate Plan - A reusable lowered Fable predicate over explicitly named roots.
- Fable
Root Query Plan - A reusable lowered Fable query over explicitly named roots.
- Fable
Root Spec - Compile-time description of a named Fable root.
- Fable
Root Value - Runtime value bound to a named Fable root.
- Fable
Transform Plan - A reusable lowered Fable transform from
InputtoOutput. - Lexeme
- A single token with the exact source slice it covers.
- Parse
- A parsed source file.
- Parse
Error - A parse error with the byte offset where it was detected.
Enums§
- Fable
Error - Error returned while parsing, lowering, or running Fable.
- Fable
Query Type - Broad result lane expected by a Fable query plan.
- Fable
Root Access - Access policy for a Fable root.
- Syntax
Kind - The kind of every token and node in a Fable concrete syntax tree.
Traits§
- Fable
Query Result - Rust result types accepted by
FableQueryPlanandFableRootQueryPlan.
Functions§
- apply
- Compile and immediately apply a Fable program to
value. - apply_
with_ intrinsics - Compile with explicit host intrinsics and immediately apply to
value. - lex
- Tokenise
srcinto a lossless stream of lexemes. - parse
- Parse Fable source into a lossless CST.
- predicate
- Compile and immediately evaluate a read-only Fable predicate.
- predicate_
with_ intrinsics - Compile with explicit host intrinsics and immediately evaluate a read-only predicate.
- query
- Compile and immediately evaluate a read-only Fable query.
- query_
with_ intrinsics - Compile with explicit host intrinsics and immediately evaluate a read-only query.
- transform
- Compile and immediately apply a Fable
intoouttransform. - transform_
with_ intrinsics - Compile with explicit host intrinsics and immediately apply a Fable transform.
Type Aliases§
- Fable
Field Bool Unary - Host function for
field -> boolintrinsics. - Fable
Field MutUnary - Host function for
field_mut -> unitintrinsics. - Fable
Field String Unary - Host function for
field -> stringintrinsics. - Fable
Float Unary - Host function for
float -> floatintrinsics. - Fable
Signed Unary - Host function for
signed number -> signed numberintrinsics. - Fable
String Binary Predicate - Host function for
(string, string) -> boolintrinsics. - Fable
String Unary - Host function for
string -> stringintrinsics. - Fable
Unsigned Unary - Host function for
unsigned number -> unsigned numberintrinsics. - Resolved
Node - A node in the resolved, text-bearing syntax tree.
- Resolved
Token - A token in the resolved, text-bearing syntax tree.
- Syntax
Element - Either a red node or token.
- Syntax
Node - A red syntax-tree node.
- Syntax
Token - A red syntax-tree token.