diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2016-05-27 15:26:46 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2016-06-15 14:41:49 +0100 |
commit | 77bb09270c70455bbd547470c4e995707d19f37d (patch) | |
tree | 3dbd57122d9931d2766fa32df0a4a29731f02d2a /testsuite/tests/partial-sigs/should_fail/T10045.stderr | |
parent | e33ca0e54f3c20a8b233a3f7b38e4968a4955300 (diff) | |
download | haskell-77bb09270c70455bbd547470c4e995707d19f37d.tar.gz |
Re-add FunTy (big patch)
With TypeInType Richard combined ForAllTy and FunTy, but that was often
awkward, and yielded little benefit becuase in practice the two were
always treated separately. This patch re-introduces FunTy. Specfically
* New type
data TyVarBinder = TvBndr TyVar VisibilityFlag
This /always/ has a TyVar it. In many places that's just what
what we want, so there are /lots/ of TyBinder -> TyVarBinder changes
* TyBinder still exists:
data TyBinder = Named TyVarBinder | Anon Type
* data Type = ForAllTy TyVarBinder Type
| FunTy Type Type
| ....
There are a LOT of knock-on changes, but they are all routine.
The Haddock submodule needs to be updated too
Diffstat (limited to 'testsuite/tests/partial-sigs/should_fail/T10045.stderr')
-rw-r--r-- | testsuite/tests/partial-sigs/should_fail/T10045.stderr | 49 |
1 files changed, 26 insertions, 23 deletions
diff --git a/testsuite/tests/partial-sigs/should_fail/T10045.stderr b/testsuite/tests/partial-sigs/should_fail/T10045.stderr index 74bfaae357..e9cac55e9e 100644 --- a/testsuite/tests/partial-sigs/should_fail/T10045.stderr +++ b/testsuite/tests/partial-sigs/should_fail/T10045.stderr @@ -1,23 +1,26 @@ -
-T10045.hs:6:18: error:
- • Found type wildcard ‘_’ standing for ‘t2 -> Bool -> t1’
- Where: ‘t1’ is a rigid type variable bound by
- the inferred type of copy :: t2 -> Bool -> t1 at T10045.hs:7:10-34
- ‘t2’ is a rigid type variable bound by
- the inferred type of copy :: t2 -> Bool -> t1 at T10045.hs:7:10-34
- To use the inferred type, enable PartialTypeSignatures
- • In the type signature: copy :: _
- In the expression:
- let
- copy :: _
- copy w from = copy w True
- in copy ws1 False
- In an equation for ‘foo’:
- foo (Meta ws1)
- = let
- copy :: _
- copy w from = copy w True
- in copy ws1 False
- • Relevant bindings include
- ws1 :: () (bound at T10045.hs:5:11)
- foo :: Meta -> t (bound at T10045.hs:5:1)
+ +T10045.hs:6:18: error: + • Found type wildcard ‘_’ standing for ‘t1 -> Bool -> t2’ + Where: ‘t1’ is a rigid type variable bound by + the inferred type of copy :: t1 -> Bool -> t2 at T10045.hs:7:10 + ‘t2’ is a rigid type variable bound by + the inferred type of copy :: t1 -> Bool -> t2 at T10045.hs:7:10 + To use the inferred type, enable PartialTypeSignatures + • In the type signature: + copy :: _ + In the expression: + let + copy :: _ + copy w from = copy w True + in copy ws1 False + In an equation for ‘foo’: + foo (Meta ws1) + = let + copy :: _ + copy w from = copy w True + in copy ws1 False + • Relevant bindings include + copy :: t1 -> Bool -> t2 (bound at T10045.hs:7:10) + ws1 :: () (bound at T10045.hs:5:11) + foo :: Meta -> t (bound at T10045.hs:5:1) + |