quint
quint copied to clipboard
Error messages for type application mismatch are not clear
/home/gabriela/projects/quint/local/test.qnt:2:13 - error: [QNT000] Couldn't unify set and list
Trying to unify Set[_t3] and List[int]
Trying to unify (Set[_t3], (_t3) => _t4) => Set[_t4] and (List[int], (int) => int) => _t5
2: val foo = [1, 2].map(x => x + 1)
^^^^^^^^^^^^^^^^^^^^^^
error: typechecking failed
Could be something like:
/home/gabriela/projects/quint/local/test.qnt:2:13 - error: [QNT000] Operator `map` expected `Set[_t3]` as its first argument, but the provided argument `[1, 2]` is a `List[int]`.
Expected: Set[_t3]
Got: List[int]
Type signature for `map` is (Set[a], (a) => b) => Set[b]
2: val foo = [1, 2].map(x => x + 1)
^^^^^^^^^^^^^^^^^^^^^^
error: typechecking failed