Why this fires¶
A schema-wide where clause must be a unary predicate accepting the assembled
schema and returning exactly bool. Field validation/defaults finish first.
schema Booking { start: int, end: int }
where |booking| booking.start < booking.endSupply labels or checked conversions in an explicit lambda when needed. An erased return is not accepted as boolean truthiness. A field whose current decoder only checks a table/number shape cannot acquire a guessed nominal, callable or representation type through this feature. Use a schema whose fields have a complete checked scalar or structural decoder.
The diagnostic carries no automatic edit: the compiler cannot invent a domain
predicate, conversion or label contract. The primary span is the authored
where keyword or the unsupported field declaration.
Schema codecs with whole-value invariants are currently runtime operations. Direct comptime codec calls and JavaScript program lowering refuse this surface explicitly. VM and AOT raw AST APIs require the checked canonical front end.