Last commit's `hs-type-check` rewrite collapsed predicate and assertion into one runtime fn that always raised on mismatch. That fixed `: Type` but broke `is a Type` / `is not a Type` (which need a bool): null is a String expected true, got nil (raised) null is not a String expected false, got true (default boolean) Restored the split. Parser now emits `(type-assert ...)` for `:` and keeps `(type-check ...)` for `is a` / `is not a`. Runtime adds: - `hs-type-check` — predicate, never raises (nil passes) - `hs-type-check-strict` — predicate, false on nil - `hs-type-assert` — value or raises - `hs-type-assert-strict` — value or raises (also raises on nil) Compiler maps `type-assert` / `type-assert-strict` to the new runtime fns. comparisonOperator 74/83 → 79/83 (+5: `is a/an`, `is not a/an` four tests plus a fifth that depended on them). typecheck stays 2/5 (no regression). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
48 KiB
48 KiB