diff options
author | Simon Peyton Jones <simonpj@microsoft.com> | 2016-08-17 12:04:30 +0100 |
---|---|---|
committer | Simon Peyton Jones <simonpj@microsoft.com> | 2016-08-17 14:38:52 +0100 |
commit | efc0372a157eadeee58bbada77c64d53590e04af (patch) | |
tree | 18c7ffbe06be62f3ef67677ee48b166c980b4484 /testsuite/tests/typecheck/should_fail/T12406.stderr | |
parent | 34da8e5127d2c65ca219162ae5cd122dd9af5e25 (diff) | |
download | haskell-efc0372a157eadeee58bbada77c64d53590e04af.tar.gz |
Not-in-scope variables are always errors
This fixes Trac #12406. A not-in-scope error shoudl be an error
even if you have -fdefer-typed-holes.
Diffstat (limited to 'testsuite/tests/typecheck/should_fail/T12406.stderr')
-rw-r--r-- | testsuite/tests/typecheck/should_fail/T12406.stderr | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/testsuite/tests/typecheck/should_fail/T12406.stderr b/testsuite/tests/typecheck/should_fail/T12406.stderr new file mode 100644 index 0000000000..85096e6184 --- /dev/null +++ b/testsuite/tests/typecheck/should_fail/T12406.stderr @@ -0,0 +1,12 @@ + +T12406.hs:20:7: error: + • Couldn't match type ‘Ref m0’ with ‘IORef’ + Expected type: IO (Ref m0 (f0 ())) + Actual type: IO (Ref IO (f0 ())) + The type variable ‘m0’ is ambiguous + • In the first argument of ‘(>>=)’, namely ‘newRef (pure ())’ + In the expression: newRef (pure ()) >>= join . readRef + In an equation for ‘foo’: foo = newRef (pure ()) >>= join . readRef + +T12406.hs:20:28: error: + Variable not in scope: join :: m0 (f0 ()) -> IO () |