summaryrefslogtreecommitdiff
path: root/dhall/tests
diff options
context:
space:
mode:
authorNadrieril2020-02-02 18:03:03 +0000
committerNadrieril2020-02-02 18:03:03 +0000
commitf3681f7a32ddb78db4d564769b50b697c54ebeac (patch)
treea65cf1d2a53d67d2ea8f808c9a8408a8f96713e7 /dhall/tests
parentb6625eccbf3f2d1bcfe1a88f4d556439281e91de (diff)
Tweak errors
Diffstat (limited to 'dhall/tests')
-rw-r--r--dhall/tests/type-errors/hurkensParadox.txt5
-rw-r--r--dhall/tests/type-errors/unit/FunctionApplicationArgumentNotMatch.txt5
-rw-r--r--dhall/tests/type-errors/unit/FunctionApplicationIsNotFunction.txt5
-rw-r--r--dhall/tests/type-errors/unit/ListLiteralEmptyNotType.txt5
-rw-r--r--dhall/tests/type-errors/unit/MergeHandlerNotFunction.txt4
-rw-r--r--dhall/tests/type-errors/unit/MergeHandlerNotMatchAlternativeType.txt3
-rw-r--r--dhall/tests/type-errors/unit/NaturalSubtractNotNatural.txt5
7 files changed, 17 insertions, 15 deletions
diff --git a/dhall/tests/type-errors/hurkensParadox.txt b/dhall/tests/type-errors/hurkensParadox.txt
index 5241517..522e1a2 100644
--- a/dhall/tests/type-errors/hurkensParadox.txt
+++ b/dhall/tests/type-errors/hurkensParadox.txt
@@ -1,4 +1,4 @@
-Type error: Unhandled error: error: Wrong type of function argument
+Type error: Unhandled error: error: wrong type of function argument
--> <current file>:6:23
|
1 | let bottom : Type = ∀(any : Type) → any
@@ -8,7 +8,8 @@ Type error: Unhandled error: error: Wrong type of function argument
...
10 | : pow (pow U) → U
11 | = λ(t : pow (pow U))
- | ^^^^^ Wrong type of function argument
| ^^^ this expects an argument of type: Kind
| ^ but this has type: Sort
|
+ = note: expected type `Kind`
+ found type `Sort`
diff --git a/dhall/tests/type-errors/unit/FunctionApplicationArgumentNotMatch.txt b/dhall/tests/type-errors/unit/FunctionApplicationArgumentNotMatch.txt
index d8811c2..01facbc 100644
--- a/dhall/tests/type-errors/unit/FunctionApplicationArgumentNotMatch.txt
+++ b/dhall/tests/type-errors/unit/FunctionApplicationArgumentNotMatch.txt
@@ -1,8 +1,9 @@
-Type error: Unhandled error: error: Wrong type of function argument
+Type error: Unhandled error: error: wrong type of function argument
--> <current file>:1:1
|
1 | (λ(_ : Natural) → _) True
- | ^^^^^^^^^^^^^^^^^^^^^^^^ Wrong type of function argument
| ^^^^^^^^^^^^^^^^^^ this expects an argument of type: Natural
| ^^^^ but this has type: Bool
|
+ = note: expected type `Natural`
+ found type `Bool`
diff --git a/dhall/tests/type-errors/unit/FunctionApplicationIsNotFunction.txt b/dhall/tests/type-errors/unit/FunctionApplicationIsNotFunction.txt
index 0732d1c..f779fd6 100644
--- a/dhall/tests/type-errors/unit/FunctionApplicationIsNotFunction.txt
+++ b/dhall/tests/type-errors/unit/FunctionApplicationIsNotFunction.txt
@@ -1,7 +1,6 @@
-Type error: Unhandled error: error: Trying to apply an argument to a value that is not a function
+Type error: Unhandled error: error: expected function, found `Bool`
--> <current file>:1:0
|
1 | True True
- | ^^^^ this has type: `Bool`
+ | ^^^^ function application requires a function
|
- = help: only functions can be applied to
diff --git a/dhall/tests/type-errors/unit/ListLiteralEmptyNotType.txt b/dhall/tests/type-errors/unit/ListLiteralEmptyNotType.txt
index 1459ca1..aa7c8c5 100644
--- a/dhall/tests/type-errors/unit/ListLiteralEmptyNotType.txt
+++ b/dhall/tests/type-errors/unit/ListLiteralEmptyNotType.txt
@@ -1,8 +1,9 @@
-Type error: Unhandled error: error: Wrong type of function argument
+Type error: Unhandled error: error: wrong type of function argument
--> <current file>:1:5
|
1 | [] : List Type
- | ^^^^^^^^^ Wrong type of function argument
| ^^^^ this expects an argument of type: Type
| ^^^^ but this has type: Kind
|
+ = note: expected type `Type`
+ found type `Kind`
diff --git a/dhall/tests/type-errors/unit/MergeHandlerNotFunction.txt b/dhall/tests/type-errors/unit/MergeHandlerNotFunction.txt
index 3a12c06..053a054 100644
--- a/dhall/tests/type-errors/unit/MergeHandlerNotFunction.txt
+++ b/dhall/tests/type-errors/unit/MergeHandlerNotFunction.txt
@@ -1,9 +1,9 @@
-Type error: Unhandled error: error: Handler is not a function
+Type error: Unhandled error: error: merge handler is not a function
--> <current file>:1:0
|
1 | merge { x = True } (< x : Bool >.x True)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ in this merge expression
- | ^^^^^^^^^^^^ the handler `x` had type: `Bool`
+ | ^^^^^^^^^^^^ the handler for `x` has type: `Bool`
| ------------------- help: the corresponding variant has type: `Bool`
|
= help: a handler for this variant must be a function that takes an input of type: `Bool`
diff --git a/dhall/tests/type-errors/unit/MergeHandlerNotMatchAlternativeType.txt b/dhall/tests/type-errors/unit/MergeHandlerNotMatchAlternativeType.txt
index 2afbc78..faca63a 100644
--- a/dhall/tests/type-errors/unit/MergeHandlerNotMatchAlternativeType.txt
+++ b/dhall/tests/type-errors/unit/MergeHandlerNotMatchAlternativeType.txt
@@ -3,7 +3,6 @@ Type error: Unhandled error: error: Wrong handler input type
|
1 | merge { x = λ(_ : Bool) → _ } (< x : Natural >.x 1)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ in this merge expression
- | ^^^^^^^^^^^^^^^^^^^^^^^ the handler `x` expects a value of type: `Bool`
+ | ^^^^^^^^^^^^^^^^^^^^^^^ the handler for `x` expects a value of type: `Bool`
| ^^^^^^^^^^^^^^^^^^^ but the corresponding variant has type: `Natural`
|
- = help: only functions can be applied to
diff --git a/dhall/tests/type-errors/unit/NaturalSubtractNotNatural.txt b/dhall/tests/type-errors/unit/NaturalSubtractNotNatural.txt
index a35b9ab..7e410c4 100644
--- a/dhall/tests/type-errors/unit/NaturalSubtractNotNatural.txt
+++ b/dhall/tests/type-errors/unit/NaturalSubtractNotNatural.txt
@@ -1,8 +1,9 @@
-Type error: Unhandled error: error: Wrong type of function argument
+Type error: Unhandled error: error: wrong type of function argument
--> <current file>:1:0
|
1 | Natural/subtract True True
- | ^^^^^^^^^^^^^^^^^^^^^ Wrong type of function argument
| ^^^^^^^^^^^^^^^^ this expects an argument of type: Natural
| ^^^^ but this has type: Bool
|
+ = note: expected type `Natural`
+ found type `Bool`