Files
rose-ash/plans
giles 19497c9fba
Some checks failed
Test, Build, and Deploy / test-build-deploy (push) Failing after 25s
ocaml: phase 4 polymorphic variants confirmation (+3 tests, 506 total)
Tokenizer already classified backtick-uppercase as a ctor identical
to a nominal one, but it had never been exercised by the suite. This
commit adds three smoke tests confirming that nullary, n-ary, and
list-of-polyvariant patterns all match:

  let x = polyvar(Foo) in match x with polyvar(Foo) -> 1 | polyvar(Bar) -> 2

  let x = polyvar(Pair) (5, 7) in
  match x with polyvar(Pair) (a, b) -> a + b | _ -> 0

  List.map (fun x -> match x with polyvar(On) -> 1 | polyvar(Off) -> 0)
           [polyvar(On); polyvar(Off); polyvar(On)]

(In the actual SX, polyvar(X) is the literal backtick-X — backticks
in this commit message are escaped to avoid shell interpretation.)
Since OCaml-on-SX is dynamic, there's no structural row inference,
but matching by tag works.
2026-05-09 01:38:09 +00:00
..