Skip to main content

Module bool_expr

Module bool_expr 

Source
Expand description

Boolean expression parser for @check and @@check constraint attributes.

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

Enums§

BoolExpr
A parsed boolean expression node.
CmpOp
A comparison operator in a boolean expression.
Operand
An operand (leaf value) in a boolean expression.

Functions§

parse_bool_expr
Parse a slice of schema tokens into a validated BoolExpr tree.