diff options
author | Nadrieril | 2019-05-06 23:17:26 +0200 |
---|---|---|
committer | Nadrieril | 2019-05-06 23:20:47 +0200 |
commit | 60129b7d1c0ea8bdf2ec666fa51957e97465e88f (patch) | |
tree | 2118155537989a1a3bfa6c51b5c476651a0ef93e /dhall/src/errors/NotAFunction.txt | |
parent | 423fdeebe9247b16744fae4b50df415bbd08be04 (diff) |
Consolidate errors in the error module
Diffstat (limited to 'dhall/src/errors/NotAFunction.txt')
-rw-r--r-- | dhall/src/errors/NotAFunction.txt | 68 |
1 files changed, 0 insertions, 68 deletions
diff --git a/dhall/src/errors/NotAFunction.txt b/dhall/src/errors/NotAFunction.txt deleted file mode 100644 index dd2695d..0000000 --- a/dhall/src/errors/NotAFunction.txt +++ /dev/null @@ -1,68 +0,0 @@ -Explanation: A function can return an output "term" that has a given "type", -like this: - - - ┌────────────────────┐ - │ ∀(x : Text) → Bool │ This is the type of a function that returns an - └────────────────────┘ output term that has type ❰Bool❱ - ⇧ - This is the type of the output term - - - ┌────────────────┐ - │ Bool → Integer │ This is the type of a function that returns an output - └────────────────┘ term that has type ❰Int❱ - ⇧ - This is the type of the output term - - -... or a function can return an output "type" that has a given "kind", like -this: - - ┌────────────────────┐ - │ ∀(a : Type) → Type │ This is the type of a function that returns an - └────────────────────┘ output type that has kind ❰Type❱ - ⇧ - This is the kind of the output type - - - ┌──────────────────────┐ - │ (Type → Type) → Type │ This is the type of a function that returns an - └──────────────────────┘ output type that has kind ❰Type❱ - ⇧ - This is the kind of the output type - - -Other outputs are $_NOT valid, like this: - - - ┌─────────────────┐ - │ ∀(x : Bool) → x │ ❰x❱ is a "term" and not a "type" nor a "kind" so the - └─────────────────┘ output cannot have "type" ❰x❱ or "kind" ❰x❱ - ⇧ - This is not a type or kind - - - ┌─────────────┐ - │ Text → True │ ❰True❱ is a "term" and not a "type" nor a "kind" so the - └─────────────┘ output cannot have "type" ❰True❱ or "kind" ❰True❱ - ⇧ - This is not a type or kind - - -You specified that your function outputs a: - -↳ $txt - -... which is neither a type nor a kind: - -Some common reasons why you might get this error: - -● You use ❰∀❱ instead of ❰λ❱ by mistake, like this: - - - ┌────────────────┐ - │ ∀(x: Bool) → x │ - └────────────────┘ - ⇧ - Using ❰λ❱ here instead of ❰∀❱ would transform this into a valid function |