Skip to main content

Module sql_expr

Module sql_expr 

Source
Expand description

Lightweight SQL expression parser for @computed and future attribute expressions.

The parser operates on tokens already produced by the schema [Lexer] and builds a small AST (SqlExpr) via recursive descent with operator precedence climbing. The AST implements [Display] so it can be round-tripped back to SQL text.

Enums§

BinOp
A binary operator in a SQL expression.
SqlExpr
A parsed SQL expression node.
UnaryOp
A unary operator in a SQL expression.

Functions§

parse_sql_expr
Parse a slice of schema tokens into a validated SqlExpr tree.