Add error when a constructor is used for a primitive argument.

Add testing for errors.
This commit is contained in:
2025-10-06 15:20:44 -07:00
parent 207d7afecf
commit be40c431fe
5 changed files with 62 additions and 34 deletions

View File

@@ -0,0 +1,9 @@
*** Process tests/LitConCase.newt
module LitConCase
ERROR at tests/LitConCase.newt:(7, 5): expected Prim.Int
foo : Int → Unit
foo 0 = MkUnit
foo MkUnit = MkUnit
^
Compile failed