Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Glasgow Haskell Compiler
GHC
Commits
64880bb7
Commit
64880bb7
authored
Mar 02, 2012
by
Simon Peyton Jones
Browse files
Modified error output and new tests for PolyKinds commit
parent
7a29e7e2
Changes
75
Hide whitespace changes
Inline
Side-by-side
testsuite/tests/arrows/should_fail/T5380.stderr
View file @
64880bb7
...
...
@@ -4,7 +4,7 @@ T5380.hs:7:27:
`not_bool' is a rigid type variable bound by
the type signature for
testB :: not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:
7
:1
at T5380.hs:
6
:1
0
In the expression: b
In the expression: proc () -> if b then f -< () else f -< ()
In an equation for `testB':
...
...
@@ -15,7 +15,7 @@ T5380.hs:7:34:
`not_unit' is a rigid type variable bound by
the type signature for
testB :: not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:
7:1
at T5380.hs:
6:42
Expected type: () -> not_unit
Actual type: () -> ()
In the expression: f
...
...
testsuite/tests/gadt/rw.stderr
View file @
64880bb7
...
...
@@ -3,7 +3,7 @@ rw.hs:14:47:
Couldn't match expected type `a' with actual type `Int'
`a' is a rigid type variable bound by
the type signature for writeInt :: T a -> IORef a -> IO ()
at rw.hs:1
3
:1
at rw.hs:1
2
:1
4
In the second argument of `writeIORef', namely `(1 :: Int)'
In the expression: writeIORef ref (1 :: Int)
In a case alternative: ~(Li x) -> writeIORef ref (1 :: Int)
...
...
@@ -12,7 +12,7 @@ rw.hs:19:51:
Couldn't match type `a' with `Bool'
`a' is a rigid type variable bound by
the type signature for readBool :: T a -> IORef a -> IO ()
at rw.hs:1
7
:1
at rw.hs:1
6
:1
4
Expected type: a -> Bool
Actual type: Bool -> Bool
In the second argument of `(.)', namely `not'
...
...
testsuite/tests/ghci/scripts/Defer02.stderr
View file @
64880bb7
...
...
@@ -37,7 +37,7 @@
Couldn't match expected type `a' with actual type `Char'
`a' is a rigid type variable bound by
the type signature for h :: a -> (Char, Char)
at ../../typecheck/should_run/Defer01.hs:3
4:1
at ../../typecheck/should_run/Defer01.hs:3
3:6
In the expression: x
In the expression: (x, 'c')
In an equation for `h': h x = (x, 'c')
...
...
testsuite/tests/ghci/scripts/Defer02.stdout
View file @
64880bb7
...
...
@@ -36,7 +36,7 @@ Hello World*** Exception: ../../typecheck/should_run/Defer01.hs:11:40:
Couldn't match expected type `a' with actual type `Char'
`a' is a rigid type variable bound by
the type signature for h :: a -> (Char, Char)
at ../../typecheck/should_run/Defer01.hs:3
4:1
at ../../typecheck/should_run/Defer01.hs:3
3:6
In the expression: x
In the expression: (x, 'c')
In an equation for `h': h x = (x, 'c')
...
...
testsuite/tests/indexed-types/should_compile/Simple14.stderr
View file @
64880bb7
...
...
@@ -7,7 +7,7 @@ Simple14.hs:17:12:
Maybe m ~ Maybe n => EQ_ z0 z0
`n' is a rigid type variable bound by
the type signature for foo :: EQ_ (Maybe m) (Maybe n)
at Simple14.hs:1
7
:1
at Simple14.hs:1
6
:1
7
Expected type: EQ_ z0 z0
Actual type: EQ_ m n
In the second argument of `eqE', namely `(eqI :: EQ_ m n)'
...
...
testsuite/tests/indexed-types/should_compile/T3208b.stderr
View file @
64880bb7
...
...
@@ -4,7 +4,7 @@ T3208b.hs:15:10:
from the context (OTerm a ~ STerm a, OBJECT a, SUBST a)
bound by the type signature for
fce' :: (OTerm a ~ STerm a, OBJECT a, SUBST a) => a -> c
at T3208b.hs:1
5:1-22
at T3208b.hs:1
4:9-56
NB: `STerm' is a type function, and may not be injective
The type variable `a0' is ambiguous
Possible fix: add a type signature that fixes these type variable(s)
...
...
@@ -18,7 +18,7 @@ T3208b.hs:15:15:
from the context (OTerm a ~ STerm a, OBJECT a, SUBST a)
bound by the type signature for
fce' :: (OTerm a ~ STerm a, OBJECT a, SUBST a) => a -> c
at T3208b.hs:1
5:1-22
at T3208b.hs:1
4:9-56
The type variable `a0' is ambiguous
Possible fix: add a type signature that fixes these type variable(s)
In the first argument of `fce', namely `(apply f)'
...
...
testsuite/tests/indexed-types/should_compile/all.T
View file @
64880bb7
...
...
@@ -21,7 +21,7 @@ test('Simple16', normal, compile, [''])
test
('
Simple17
',
normal
,
compile
,
[''])
test
('
Simple18
',
normal
,
compile
,
[''])
test
('
Simple19
',
normal
,
compile
,
[''])
test
('
Simple20
',
expect_broken
(
4296
),
compile
,
['
-fcontext-stack=
5
0
'])
test
('
Simple20
',
expect_broken
(
4296
),
compile
,
['
-fcontext-stack=
1
0
'])
test
('
Simple21
',
normal
,
compile
,
[''])
test
('
Simple22
',
normal
,
compile
,
[''])
test
('
Simple23
',
normal
,
compile
,
[''])
...
...
testsuite/tests/indexed-types/should_fail/GADTwrong1.stderr
View file @
64880bb7
...
...
@@ -7,7 +7,7 @@ GADTwrong1.hs:12:19:
in a case alternative
at GADTwrong1.hs:12:12-14
`b' is a rigid type variable bound by
the type signature for coerce :: a -> b at GADTwrong1.hs:1
1:1
the type signature for coerce :: a -> b at GADTwrong1.hs:1
0:20
`a1' is a rigid type variable bound by
a pattern with constructor
T :: forall a. a -> T (Const a),
...
...
testsuite/tests/indexed-types/should_fail/NoMatchErr.stderr
View file @
64880bb7
...
...
@@ -3,7 +3,7 @@ NoMatchErr.hs:20:5:
Could not deduce (Memo d ~ Memo d0)
from the context (Fun d)
bound by the type signature for f :: Fun d => Memo d a -> Memo d a
at NoMatchErr.hs:
20:1-15
at NoMatchErr.hs:
19:7-37
NB: `Memo' is a type function, and may not be injective
The type variable `d0' is ambiguous
Possible fix: add a type signature that fixes these type variable(s)
...
...
testsuite/tests/indexed-types/should_fail/SimpleFail15.stderr
View file @
64880bb7
SimpleFail15.hs:5:
1:
Illegal polymorphic or qualified type: a ~ b => t
Perhaps you intended to use -XRankNTypes or -XRank2Types
In the type signature for `foo':
foo :: (a, b) -> (a ~ b => t) -> (a, b)
SimpleFail15.hs:5:
8:
Illegal polymorphic or qualified type: a ~ b => t
Perhaps you intended to use -XRankNTypes or -XRank2Types
In the type signature for `foo':
foo :: (a, b) -> (a ~ b => t) -> (a, b)
testsuite/tests/indexed-types/should_fail/SimpleFail5a.stderr
View file @
64880bb7
...
...
@@ -3,7 +3,7 @@ SimpleFail5a.hs:31:11:
Couldn't match type `a' with `Int'
`a' is a rigid type variable bound by
the type signature for bar3wrong :: S3 a -> a
at SimpleFail5a.hs:3
1
:1
at SimpleFail5a.hs:3
0
:1
7
Expected type: S3 a
Actual type: S3 Int
In the pattern: D3Int
...
...
testsuite/tests/indexed-types/should_fail/SimpleFail6.stderr
View file @
64880bb7
SimpleFail6.hs:7:11: Illegal repeated type variable `a'
SimpleFail6.hs:7:11:
Conflicting definitions for `a'
Bound at: SimpleFail6.hs:7:11
SimpleFail6.hs:7:13
testsuite/tests/indexed-types/should_fail/SkolemOccursLoop.hs
View file @
64880bb7
{-# OPTIONS_GHC -fcontext-stack=
10
#-}
{-# OPTIONS_GHC -fcontext-stack=
3
#-}
{-# LANGUAGE TypeFamilies, FlexibleContexts, EmptyDataDecls #-}
module
SkolemOccursLoop
where
...
...
testsuite/tests/indexed-types/should_fail/SkolemOccursLoop.stderr
View file @
64880bb7
SkolemOccursLoop.hs:18:0:
Couldn't match expected type `F a'
against inferred type `[T (F (T (F a)))]'
When generalising the type(s) for `test1'
SkolemOccursLoop.hs:31:0:
Couldn't match expected type `S (G (a, a))'
against inferred type `G [S (G (a, a))]'
When generalising the type(s) for `test2'
Skolem occurs loop
testsuite/tests/indexed-types/should_fail/T1900.stderr
View file @
64880bb7
...
...
@@ -11,7 +11,7 @@ T1900.hs:14:22:
Could not deduce (Depend s0 ~ Depend s)
from the context (Bug s)
bound by the type signature for check :: Bug s => Depend s -> Bool
at T1900.hs:1
4
:1
-22
at T1900.hs:1
3
:1
0-36
NB: `Depend' is a type function, and may not be injective
The type variable `s0' is ambiguous
Possible fix: add a type signature that fixes these type variable(s)
...
...
testsuite/tests/indexed-types/should_fail/T3330a.stderr
View file @
64880bb7
T3330a.hs:19:34:
Couldn't match type `s' with `(->) (s0 ix1 -> ix1)'
`s' is a rigid type variable bound by
the type signature for children :: s ix -> PF s r ix -> [AnyF s]
at T3330a.hs:1
9
:1
Expected type: (s0 ix0 -> ix1) -> r ix1 -> Writer [AnyF s] (r ix1)
Actual type: s ix
In the first argument of `hmapM', namely `p'
In the first argument of `execWriter', namely `(hmapM p collect x)'
In the expression: execWriter (hmapM p collect x)
T3330a.hs:19:36:
Couldn't match type `ix' with `r ix0 -> Writer [AnyF s0] (r ix0)'
`ix' is a rigid type variable bound by
the type signature for children :: s ix -> PF s r ix -> [AnyF s]
at T3330a.hs:1
9
:1
Expected type: s0 ix0 -> ix
Actual type: s0 ix0 -> r ix0 -> Writer [AnyF s0] (r ix0)
In the second argument of `hmapM', namely `collect'
In the first argument of `execWriter', namely `(hmapM p collect x)'
In the expression: execWriter (hmapM p collect x)
T3330a.hs:19:34:
Couldn't match type `s' with `(->) (s0 ix1 -> ix1)'
`s' is a rigid type variable bound by
the type signature for children :: s ix -> PF s r ix -> [AnyF s]
at T3330a.hs:1
8
:1
3
Expected type: (s0 ix0 -> ix1) -> r ix1 -> Writer [AnyF s] (r ix1)
Actual type: s ix
In the first argument of `hmapM', namely `p'
In the first argument of `execWriter', namely `(hmapM p collect x)'
In the expression: execWriter (hmapM p collect x)
T3330a.hs:19:36:
Couldn't match type `ix' with `r ix0 -> Writer [AnyF s0] (r ix0)'
`ix' is a rigid type variable bound by
the type signature for children :: s ix -> PF s r ix -> [AnyF s]
at T3330a.hs:1
8
:1
5
Expected type: s0 ix0 -> ix
Actual type: s0 ix0 -> r ix0 -> Writer [AnyF s0] (r ix0)
In the second argument of `hmapM', namely `collect'
In the first argument of `execWriter', namely `(hmapM p collect x)'
In the expression: execWriter (hmapM p collect x)
testsuite/tests/indexed-types/should_fail/T3440.stderr
View file @
64880bb7
...
...
@@ -8,7 +8,7 @@ T3440.hs:11:22:
at T3440.hs:11:9-16
`a' is a rigid type variable bound by
the type signature for unwrap :: GADT (Fam a) -> (a, Fam a)
at T3440.hs:1
1:
1
at T3440.hs:1
0:2
1
`a1' is a rigid type variable bound by
a pattern with constructor
GADT :: forall a. a -> Fam a -> GADT (Fam a),
...
...
testsuite/tests/indexed-types/should_fail/T4093a.stderr
View file @
64880bb7
...
...
@@ -3,10 +3,10 @@ T4093a.hs:8:8:
Could not deduce (e ~ ())
from the context (Foo e ~ Maybe e)
bound by the type signature for hang :: Foo e ~ Maybe e => Foo e
at T4093a.hs:
8:1-1
4
at T4093a.hs:
7:9-3
4
`e' is a rigid type variable bound by
the type signature for hang :: Foo e ~ Maybe e => Foo e
at T4093a.hs:
8
:1
at T4093a.hs:
7
:1
4
Expected type: Foo e
Actual type: Maybe ()
In the return type of a call of `Just'
...
...
testsuite/tests/indexed-types/should_fail/T4093b.stderr
View file @
64880bb7
...
...
@@ -7,13 +7,13 @@ T4093b.hs:31:13:
blockToNodeList :: (EitherCO e (A C O n) (A O O n) ~ A e O n,
EitherCO x (A C C n) (A C O n) ~ A C x n) =>
Block n e x -> A e x n
at T4093b.hs:(2
5,1)-(34,19
)
at T4093b.hs:(2
0,3)-(22,26
)
`e' is a rigid type variable bound by
the type signature for
blockToNodeList :: (EitherCO e (A C O n) (A O O n) ~ A e O n,
EitherCO x (A C C n) (A C O n) ~ A C x n) =>
Block n e x -> A e x n
at T4093b.hs:2
5
:1
at T4093b.hs:2
0
:1
2
Expected type: EitherCO e (A C O n) (A O O n)
Actual type: (MaybeC C (n C O), MaybeC O (n O C))
In the expression: (JustC n, NothingC)
...
...
testsuite/tests/indexed-types/should_fail/T4179.stderr
View file @
64880bb7
...
...
@@ -6,7 +6,7 @@ T4179.hs:26:16:
bound by the type signature for
fCon :: (Functor x, DoC (FCon x)) =>
Con x -> A2 (FCon x) -> A3 (FCon x)
at T4179.hs:2
6:1-17
at T4179.hs:2
5:9-72
NB: `A3' is a type function, and may not be injective
Expected type: x (A2 (x (Con x)) -> A3 (x (Con x)))
-> A2 (x (Con x)) -> A3 (x (Con x))
...
...
Prev
1
2
3
4
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment