diff options
Diffstat (limited to 'testsuite/tests')
21 files changed, 391 insertions, 443 deletions
diff --git a/testsuite/tests/annotations/should_fail/annfail10.stderr b/testsuite/tests/annotations/should_fail/annfail10.stderr index 5ac8ab50b3..a8236709c2 100644 --- a/testsuite/tests/annotations/should_fail/annfail10.stderr +++ b/testsuite/tests/annotations/should_fail/annfail10.stderr @@ -1,25 +1,27 @@ -
-annfail10.hs:9:1:
- No instance for (Data a0) arising from an annotation
- The type variable ‘a0’ is ambiguous
- Note: there are several potential instances:
- instance (Data a, Data b) => Data (Either a b)
- -- Defined in ‘Data.Data’
- instance Data All -- Defined in ‘Data.Data’
- instance (Data (f a), Data a, Typeable f) => Data (Alt f a)
- -- Defined in ‘Data.Data’
- ...plus 39 others
- In the annotation: {-# ANN f 1 #-}
-
-annfail10.hs:9:11:
- No instance for (Num a0) arising from the literal ‘1’
- The type variable ‘a0’ is ambiguous
- Note: there are several potential instances:
- instance forall (k :: BOX) (f :: k -> *) (a :: k).
- Num (f a) =>
- Num (Alt f a)
- -- Defined in ‘Data.Monoid’
- instance Num a => Num (Product a) -- Defined in ‘Data.Monoid’
- instance Num a => Num (Sum a) -- Defined in ‘Data.Monoid’
- ...plus 14 others
- In the annotation: {-# ANN f 1 #-}
+ +annfail10.hs:9:1: error: + No instance for (Data a0) arising from an annotation + The type variable ‘a0’ is ambiguous + Potential instances: + instance (Data a, Data b) => Data (Either a b) + -- Defined in ‘Data.Data’ + instance Data All -- Defined in ‘Data.Data’ + instance (Data (f a), Data a, Typeable f) => Data (Alt f a) + -- Defined in ‘Data.Data’ + ...plus 39 others + (use -fprint-potential-instances to see them all) + In the annotation: {-# ANN f 1 #-} + +annfail10.hs:9:11: error: + No instance for (Num a0) arising from the literal ‘1’ + The type variable ‘a0’ is ambiguous + Potential instances: + instance forall (k :: BOX) (f :: k -> *) (a :: k). + Num (f a) => + Num (Alt f a) + -- Defined in ‘Data.Monoid’ + instance Num a => Num (Product a) -- Defined in ‘Data.Monoid’ + instance Num a => Num (Sum a) -- Defined in ‘Data.Monoid’ + ...plus 14 others + (use -fprint-potential-instances to see them all) + In the annotation: {-# ANN f 1 #-} diff --git a/testsuite/tests/ghci.debugger/scripts/break006.stderr b/testsuite/tests/ghci.debugger/scripts/break006.stderr index 9822dd785b..bf96e55e9e 100644 --- a/testsuite/tests/ghci.debugger/scripts/break006.stderr +++ b/testsuite/tests/ghci.debugger/scripts/break006.stderr @@ -1,32 +1,34 @@ -
-<interactive>:5:1:
- No instance for (Show t1) arising from a use of ‘print’
- Cannot resolve unknown runtime type ‘t1’
- Use :print or :force to determine these types
- Relevant bindings include it :: t1 (bound at <interactive>:5:1)
- Note: there are several potential instances:
- instance (Show a, Show b) => Show (Either a b)
- -- Defined in ‘Data.Either’
- instance Show All -- Defined in ‘Data.Monoid’
- instance forall (k :: BOX) (f :: k -> *) (a :: k).
- Show (f a) =>
- Show (Alt f a)
- -- Defined in ‘Data.Monoid’
- ...plus 33 others
- In a stmt of an interactive GHCi command: print it
-
-<interactive>:7:1:
- No instance for (Show t1) arising from a use of ‘print’
- Cannot resolve unknown runtime type ‘t1’
- Use :print or :force to determine these types
- Relevant bindings include it :: t1 (bound at <interactive>:7:1)
- Note: there are several potential instances:
- instance (Show a, Show b) => Show (Either a b)
- -- Defined in ‘Data.Either’
- instance Show All -- Defined in ‘Data.Monoid’
- instance forall (k :: BOX) (f :: k -> *) (a :: k).
- Show (f a) =>
- Show (Alt f a)
- -- Defined in ‘Data.Monoid’
- ...plus 33 others
- In a stmt of an interactive GHCi command: print it
+ +<interactive>:5:1: error: + No instance for (Show t1) arising from a use of ‘print’ + Cannot resolve unknown runtime type ‘t1’ + Use :print or :force to determine these types + Relevant bindings include it :: t1 (bound at <interactive>:5:1) + Potential instances: + instance (Show a, Show b) => Show (Either a b) + -- Defined in ‘Data.Either’ + instance Show All -- Defined in ‘Data.Monoid’ + instance forall (k :: BOX) (f :: k -> *) (a :: k). + Show (f a) => + Show (Alt f a) + -- Defined in ‘Data.Monoid’ + ...plus 33 others + (use -fprint-potential-instances to see them all) + In a stmt of an interactive GHCi command: print it + +<interactive>:7:1: error: + No instance for (Show t1) arising from a use of ‘print’ + Cannot resolve unknown runtime type ‘t1’ + Use :print or :force to determine these types + Relevant bindings include it :: t1 (bound at <interactive>:7:1) + Potential instances: + instance (Show a, Show b) => Show (Either a b) + -- Defined in ‘Data.Either’ + instance Show All -- Defined in ‘Data.Monoid’ + instance forall (k :: BOX) (f :: k -> *) (a :: k). + Show (f a) => + Show (Alt f a) + -- Defined in ‘Data.Monoid’ + ...plus 33 others + (use -fprint-potential-instances to see them all) + In a stmt of an interactive GHCi command: print it diff --git a/testsuite/tests/ghci.debugger/scripts/print019.stderr b/testsuite/tests/ghci.debugger/scripts/print019.stderr index 15c9f839db..39bc29fae9 100644 --- a/testsuite/tests/ghci.debugger/scripts/print019.stderr +++ b/testsuite/tests/ghci.debugger/scripts/print019.stderr @@ -1,12 +1,13 @@ -<interactive>:10:1: +<interactive>:10:1: error: No instance for (Show a1) arising from a use of ‘print’ Cannot resolve unknown runtime type ‘a1’ Use :print or :force to determine these types Relevant bindings include it :: a1 (bound at <interactive>:10:1) - Note: there are several potential instances: + Potential instances: instance Show TyCon -- Defined in ‘Data.Typeable.Internal’ instance Show TypeRep -- Defined in ‘Data.Typeable.Internal’ instance Show a => Show (Maybe a) -- Defined in ‘GHC.Show’ ...plus 30 others + (use -fprint-potential-instances to see them all) In a stmt of an interactive GHCi command: print it diff --git a/testsuite/tests/ghci/scripts/Defer02.stderr b/testsuite/tests/ghci/scripts/Defer02.stderr index cc5ae21d20..b2a5efefc3 100644 --- a/testsuite/tests/ghci/scripts/Defer02.stderr +++ b/testsuite/tests/ghci/scripts/Defer02.stderr @@ -1,193 +1,194 @@ -
-..\..\typecheck\should_run\Defer01.hs:11:40: warning:
- Couldn't match type ‘Char’ with ‘[Char]’
- Expected type: String
- Actual type: Char
- In the first argument of ‘putStr’, namely ‘','’
- In the second argument of ‘(>>)’, namely ‘putStr ','’
- In the expression: putStr "Hello World" >> putStr ','
-
-..\..\typecheck\should_run\Defer01.hs:14:5: warning:
- Couldn't match expected type ‘Int’ with actual type ‘Char’
- In the expression: 'p'
- In an equation for ‘a’: a = 'p'
-
-..\..\typecheck\should_run\Defer01.hs:18:9: warning:
- No instance for (Eq B) arising from a use of ‘==’
- In the expression: x == x
- In an equation for ‘b’: b x = x == x
-
-..\..\typecheck\should_run\Defer01.hs:25:4: warning:
- Couldn't match type ‘Int’ with ‘Bool’
- Inaccessible code in
- a pattern with constructor: C2 :: Bool -> C Bool,
- in an equation for ‘c’
- In the pattern: C2 x
- In an equation for ‘c’: c (C2 x) = True
-
-..\..\typecheck\should_run\Defer01.hs:28:5: warning:
- No instance for (Num (a -> a)) arising from the literal ‘1’
- (maybe you haven't applied a function to enough arguments?)
- In the expression: 1
- In an equation for ‘d’: d = 1
-
-..\..\typecheck\should_run\Defer01.hs:31:5: warning:
- Couldn't match expected type ‘Char -> t’ with actual type ‘Char’
- Relevant bindings include
- f :: t (bound at ..\..\typecheck\should_run\Defer01.hs:31:1)
- The function ‘e’ is applied to one argument,
- but its type ‘Char’ has none
- In the expression: e 'q'
- In an equation for ‘f’: f = e 'q'
-
-..\..\typecheck\should_run\Defer01.hs:34:8: warning:
- Couldn't match expected type ‘Char’ with actual type ‘a’
- ‘a’ is a rigid type variable bound by
- the type signature for:
- h :: a -> (Char, Char)
- at ..\..\typecheck\should_run\Defer01.hs:33:6
- Relevant bindings include
- x :: a (bound at ..\..\typecheck\should_run\Defer01.hs:34:3)
- h :: a -> (Char, Char)
- (bound at ..\..\typecheck\should_run\Defer01.hs:34:1)
- In the expression: x
- In the expression: (x, 'c')
-
-..\..\typecheck\should_run\Defer01.hs:39:17: warning:
- Couldn't match expected type ‘Bool’ with actual type ‘T a’
- Relevant bindings include
- a :: a (bound at ..\..\typecheck\should_run\Defer01.hs:39:3)
- i :: a -> () (bound at ..\..\typecheck\should_run\Defer01.hs:39:1)
- In the first argument of ‘not’, namely ‘(K a)’
- In the expression: (not (K a))
-
-..\..\typecheck\should_run\Defer01.hs:43:5: warning:
- No instance for (MyClass a1) arising from a use of ‘myOp’
- In the expression: myOp 23
- In an equation for ‘j’: j = myOp 23
-
-..\..\typecheck\should_run\Defer01.hs:43:10: warning:
- No instance for (Num a1) arising from the literal ‘23’
- The type variable ‘a1’ is ambiguous
- Note: there are several potential instances:
- instance Num Integer -- Defined in ‘GHC.Num’
- instance Num Double -- Defined in ‘GHC.Float’
- instance Num Float -- Defined in ‘GHC.Float’
- ...plus two others
- In the first argument of ‘myOp’, namely ‘23’
- In the expression: myOp 23
- In an equation for ‘j’: j = myOp 23
-
-..\..\typecheck\should_run\Defer01.hs:45:6: warning:
- Couldn't match type ‘Int’ with ‘Bool’
- Inaccessible code in
- the type signature for:
- k :: (Int ~ Bool) => Int -> Bool
- In the ambiguity check for the type signature for ‘k’:
- k :: (Int ~ Bool) => Int -> Bool
- To defer the ambiguity check to use sites, enable AllowAmbiguousTypes
- In the type signature for ‘k’: k :: (Int ~ Bool) => Int -> Bool
-
-..\..\typecheck\should_run\Defer01.hs:45:6: warning:
- Couldn't match expected type ‘Bool’ with actual type ‘Int’
- In the ambiguity check for the type signature for ‘k’:
- k :: (Int ~ Bool) => Int -> Bool
- To defer the ambiguity check to use sites, enable AllowAmbiguousTypes
- In the type signature for ‘k’: k :: (Int ~ Bool) => Int -> Bool
-
-..\..\typecheck\should_run\Defer01.hs:45:6: warning:
- Couldn't match type ‘Int’ with ‘Bool’
- Inaccessible code in
- the type signature for:
- k :: (Int ~ Bool) => Int -> Bool
-
-..\..\typecheck\should_run\Defer01.hs:46:7: warning:
- Couldn't match expected type ‘Bool’ with actual type ‘Int’
- In the expression: x
- In an equation for ‘k’: k x = x
-
-..\..\typecheck\should_run\Defer01.hs:49:5: warning:
- Couldn't match expected type ‘IO a0’
- with actual type ‘Char -> IO ()’
- Probable cause: ‘putChar’ is applied to too few arguments
- In the first argument of ‘(>>)’, namely ‘putChar’
- In the expression: putChar >> putChar 'p'
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:11:40: error:
- Couldn't match type ‘Char’ with ‘[Char]’
- Expected type: String
- Actual type: Char
- In the first argument of ‘putStr’, namely ‘','’
- In the second argument of ‘(>>)’, namely ‘putStr ','’
- In the expression: putStr "Hello World" >> putStr ','
-(deferred type error)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:14:5: error:
- Couldn't match expected type ‘Int’ with actual type ‘Char’
- In the expression: 'p'
- In an equation for ‘a’: a = 'p'
-(deferred type error)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:18:9: error:
- No instance for (Eq B) arising from a use of ‘==’
- In the expression: x == x
- In an equation for ‘b’: b x = x == x
-(deferred type error)
-
-<interactive>:7:11: error:
- Couldn't match type ‘Bool’ with ‘Int’
- Expected type: C Int
- Actual type: C Bool
- In the first argument of ‘c’, namely ‘(C2 True)’
- In the first argument of ‘print’, namely ‘(c (C2 True))’
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:28:5: error:
- No instance for (Num (a -> a)) arising from the literal ‘1’
- (maybe you haven't applied a function to enough arguments?)
- In the expression: 1
- In an equation for ‘d’: d = 1
-(deferred type error)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:31:5: error:
- Couldn't match expected type ‘Char -> t’ with actual type ‘Char’
- Relevant bindings include
- f :: t (bound at ..\..\typecheck\should_run\Defer01.hs:31:1)
- The function ‘e’ is applied to one argument,
- but its type ‘Char’ has none
- In the expression: e 'q'
- In an equation for ‘f’: f = e 'q'
-(deferred type error)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:34:8: error:
- Couldn't match expected type ‘Char’ with actual type ‘a’
- ‘a’ is a rigid type variable bound by
- the type signature for:
- h :: a -> (Char, Char)
- at ..\..\typecheck\should_run\Defer01.hs:33:6
- Relevant bindings include
- x :: a (bound at ..\..\typecheck\should_run\Defer01.hs:34:3)
- h :: a -> (Char, Char)
- (bound at ..\..\typecheck\should_run\Defer01.hs:34:1)
- In the expression: x
- In the expression: (x, 'c')
-(deferred type error)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:39:17: error:
- Couldn't match expected type ‘Bool’ with actual type ‘T a’
- Relevant bindings include
- a :: a (bound at ..\..\typecheck\should_run\Defer01.hs:39:3)
- i :: a -> () (bound at ..\..\typecheck\should_run\Defer01.hs:39:1)
- In the first argument of ‘not’, namely ‘(K a)’
- In the expression: (not (K a))
-(deferred type error)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:43:5: error:
- No instance for (MyClass a1) arising from a use of ‘myOp’
- In the expression: myOp 23
- In an equation for ‘j’: j = myOp 23
-(deferred type error)
-
-<interactive>:13:8: error:
- Couldn't match expected type ‘Bool’ with actual type ‘Int’
- In the first argument of ‘print’, namely ‘(k 2)’
- In the expression: print (k 2)
- In an equation for ‘it’: it = print (k 2)
-*** Exception: ..\..\typecheck\should_run\Defer01.hs:49:5: error:
- Couldn't match expected type ‘IO a0’
- with actual type ‘Char -> IO ()’
- Probable cause: ‘putChar’ is applied to too few arguments
- In the first argument of ‘(>>)’, namely ‘putChar’
- In the expression: putChar >> putChar 'p'
-(deferred type error)
+ +../../typecheck/should_run/Defer01.hs:11:40: warning: + Couldn't match type ‘Char’ with ‘[Char]’ + Expected type: String + Actual type: Char + In the first argument of ‘putStr’, namely ‘','’ + In the second argument of ‘(>>)’, namely ‘putStr ','’ + In the expression: putStr "Hello World" >> putStr ',' + +../../typecheck/should_run/Defer01.hs:14:5: warning: + Couldn't match expected type ‘Int’ with actual type ‘Char’ + In the expression: 'p' + In an equation for ‘a’: a = 'p' + +../../typecheck/should_run/Defer01.hs:18:9: warning: + No instance for (Eq B) arising from a use of ‘==’ + In the expression: x == x + In an equation for ‘b’: b x = x == x + +../../typecheck/should_run/Defer01.hs:25:4: warning: + Couldn't match type ‘Int’ with ‘Bool’ + Inaccessible code in + a pattern with constructor: C2 :: Bool -> C Bool, + in an equation for ‘c’ + In the pattern: C2 x + In an equation for ‘c’: c (C2 x) = True + +../../typecheck/should_run/Defer01.hs:28:5: warning: + No instance for (Num (a -> a)) arising from the literal ‘1’ + (maybe you haven't applied a function to enough arguments?) + In the expression: 1 + In an equation for ‘d’: d = 1 + +../../typecheck/should_run/Defer01.hs:31:5: warning: + Couldn't match expected type ‘Char -> t’ with actual type ‘Char’ + Relevant bindings include + f :: t (bound at ../../typecheck/should_run/Defer01.hs:31:1) + The function ‘e’ is applied to one argument, + but its type ‘Char’ has none + In the expression: e 'q' + In an equation for ‘f’: f = e 'q' + +../../typecheck/should_run/Defer01.hs:34:8: warning: + Couldn't match expected type ‘Char’ with actual type ‘a’ + ‘a’ is a rigid type variable bound by + the type signature for: + h :: a -> (Char, Char) + at ../../typecheck/should_run/Defer01.hs:33:6 + Relevant bindings include + x :: a (bound at ../../typecheck/should_run/Defer01.hs:34:3) + h :: a -> (Char, Char) + (bound at ../../typecheck/should_run/Defer01.hs:34:1) + In the expression: x + In the expression: (x, 'c') + +../../typecheck/should_run/Defer01.hs:39:17: warning: + Couldn't match expected type ‘Bool’ with actual type ‘T a’ + Relevant bindings include + a :: a (bound at ../../typecheck/should_run/Defer01.hs:39:3) + i :: a -> () (bound at ../../typecheck/should_run/Defer01.hs:39:1) + In the first argument of ‘not’, namely ‘(K a)’ + In the expression: (not (K a)) + +../../typecheck/should_run/Defer01.hs:43:5: warning: + No instance for (MyClass a1) arising from a use of ‘myOp’ + In the expression: myOp 23 + In an equation for ‘j’: j = myOp 23 + +../../typecheck/should_run/Defer01.hs:43:10: warning: + No instance for (Num a1) arising from the literal ‘23’ + The type variable ‘a1’ is ambiguous + Potential instances: + instance Num Integer -- Defined in ‘GHC.Num’ + instance Num Double -- Defined in ‘GHC.Float’ + instance Num Float -- Defined in ‘GHC.Float’ + ...plus two others + (use -fprint-potential-instances to see them all) + In the first argument of ‘myOp’, namely ‘23’ + In the expression: myOp 23 + In an equation for ‘j’: j = myOp 23 + +../../typecheck/should_run/Defer01.hs:45:6: warning: + Couldn't match type ‘Int’ with ‘Bool’ + Inaccessible code in + the type signature for: + k :: (Int ~ Bool) => Int -> Bool + In the ambiguity check for the type signature for ‘k’: + k :: (Int ~ Bool) => Int -> Bool + To defer the ambiguity check to use sites, enable AllowAmbiguousTypes + In the type signature for ‘k’: k :: (Int ~ Bool) => Int -> Bool + +../../typecheck/should_run/Defer01.hs:45:6: warning: + Couldn't match expected type ‘Bool’ with actual type ‘Int’ + In the ambiguity check for the type signature for ‘k’: + k :: (Int ~ Bool) => Int -> Bool + To defer the ambiguity check to use sites, enable AllowAmbiguousTypes + In the type signature for ‘k’: k :: (Int ~ Bool) => Int -> Bool + +../../typecheck/should_run/Defer01.hs:45:6: warning: + Couldn't match type ‘Int’ with ‘Bool’ + Inaccessible code in + the type signature for: + k :: (Int ~ Bool) => Int -> Bool + +../../typecheck/should_run/Defer01.hs:46:7: warning: + Couldn't match expected type ‘Bool’ with actual type ‘Int’ + In the expression: x + In an equation for ‘k’: k x = x + +../../typecheck/should_run/Defer01.hs:49:5: warning: + Couldn't match expected type ‘IO a0’ + with actual type ‘Char -> IO ()’ + Probable cause: ‘putChar’ is applied to too few arguments + In the first argument of ‘(>>)’, namely ‘putChar’ + In the expression: putChar >> putChar 'p' +*** Exception: ../../typecheck/should_run/Defer01.hs:11:40: error: + Couldn't match type ‘Char’ with ‘[Char]’ + Expected type: String + Actual type: Char + In the first argument of ‘putStr’, namely ‘','’ + In the second argument of ‘(>>)’, namely ‘putStr ','’ + In the expression: putStr "Hello World" >> putStr ',' +(deferred type error) +*** Exception: ../../typecheck/should_run/Defer01.hs:14:5: error: + Couldn't match expected type ‘Int’ with actual type ‘Char’ + In the expression: 'p' + In an equation for ‘a’: a = 'p' +(deferred type error) +*** Exception: ../../typecheck/should_run/Defer01.hs:18:9: error: + No instance for (Eq B) arising from a use of ‘==’ + In the expression: x == x + In an equation for ‘b’: b x = x == x +(deferred type error) + +<interactive>:7:11: error: + Couldn't match type ‘Bool’ with ‘Int’ + Expected type: C Int + Actual type: C Bool + In the first argument of ‘c’, namely ‘(C2 True)’ + In the first argument of ‘print’, namely ‘(c (C2 True))’ +*** Exception: ../../typecheck/should_run/Defer01.hs:28:5: error: + No instance for (Num (a -> a)) arising from the literal ‘1’ + (maybe you haven't applied a function to enough arguments?) + In the expression: 1 + In an equation for ‘d’: d = 1 +(deferred type error) +*** Exception: ../../typecheck/should_run/Defer01.hs:31:5: error: + Couldn't match expected type ‘Char -> t’ with actual type ‘Char’ + Relevant bindings include + f :: t (bound at ../../typecheck/should_run/Defer01.hs:31:1) + The function ‘e’ is applied to one argument, + but its type ‘Char’ has none + In the expression: e 'q' + In an equation for ‘f’: f = e 'q' +(deferred type error) +*** Exception: ../../typecheck/should_run/Defer01.hs:34:8: error: + Couldn't match expected type ‘Char’ with actual type ‘a’ + ‘a’ is a rigid type variable bound by + the type signature for: + h :: a -> (Char, Char) + at ../../typecheck/should_run/Defer01.hs:33:6 + Relevant bindings include + x :: a (bound at ../../typecheck/should_run/Defer01.hs:34:3) + h :: a -> (Char, Char) + (bound at ../../typecheck/should_run/Defer01.hs:34:1) + In the expression: x + In the expression: (x, 'c') +(deferred type error) +*** Exception: ../../typecheck/should_run/Defer01.hs:39:17: error: + Couldn't match expected type ‘Bool’ with actual type ‘T a’ + Relevant bindings include + a :: a (bound at ../../typecheck/should_run/Defer01.hs:39:3) + i :: a -> () (bound at ../../typecheck/should_run/Defer01.hs:39:1) + In the first argument of ‘not’, namely ‘(K a)’ + In the expression: (not (K a)) +(deferred type error) +*** Exception: ../../typecheck/should_run/Defer01.hs:43:5: error: + No instance for (MyClass a1) arising from a use of ‘myOp’ + In the expression: myOp 23 + In an equation for ‘j’: j = myOp 23 +(deferred type error) + +<interactive>:13:8: error: + Couldn't match expected type ‘Bool’ with actual type ‘Int’ + In the first argument of ‘print’, namely ‘(k 2)’ + In the expression: print (k 2) + In an equation for ‘it’: it = print (k 2) +*** Exception: ../../typecheck/should_run/Defer01.hs:49:5: error: + Couldn't match expected type ‘IO a0’ + with actual type ‘Char -> IO ()’ + Probable cause: ‘putChar’ is applied to too few arguments + In the first argument of ‘(>>)’, namely ‘putChar’ + In the expression: putChar >> putChar 'p' +(deferred type error) diff --git a/testsuite/tests/indexed-types/should_fail/T4485.stderr b/testsuite/tests/indexed-types/should_fail/T4485.stderr index 320d9a5195..f05eeace6e 100644 --- a/testsuite/tests/indexed-types/should_fail/T4485.stderr +++ b/testsuite/tests/indexed-types/should_fail/T4485.stderr @@ -1,5 +1,5 @@ -T4485.hs:50:15: +T4485.hs:50:15: error: Overlapping instances for EmbedAsChild (IdentityT IO) (XMLGenT m0 (XML m0)) arising from a use of ‘asChild’ @@ -18,10 +18,10 @@ T4485.hs:50:15: In an equation for ‘asChild’: asChild b = asChild $ (genElement "foo") -T4485.hs:50:26: +T4485.hs:50:26: error: No instance for (XMLGen m0) arising from a use of ‘genElement’ The type variable ‘m0’ is ambiguous - Note: there is a potential instance available: + Potential instances: instance XMLGen (IdentityT m) -- Defined at T4485.hs:37:10 In the second argument of ‘($)’, namely ‘(genElement "foo")’ In the expression: asChild $ (genElement "foo") diff --git a/testsuite/tests/overloadedlists/should_fail/overloadedlistsfail01.stderr b/testsuite/tests/overloadedlists/should_fail/overloadedlistsfail01.stderr index 52658fdd07..79b78658b3 100644 --- a/testsuite/tests/overloadedlists/should_fail/overloadedlistsfail01.stderr +++ b/testsuite/tests/overloadedlists/should_fail/overloadedlistsfail01.stderr @@ -1,33 +1,35 @@ -
-overloadedlistsfail01.hs:5:8:
- No instance for (Show a0) arising from a use of ‘print’
- The type variable ‘a0’ is ambiguous
- Note: there are several potential instances:
- instance [safe] Show Version -- Defined in ‘Data.Version’
- instance Show a => Show (Maybe a) -- Defined in ‘GHC.Show’
- instance Show Ordering -- Defined in ‘GHC.Show’
- ...plus 23 others
- In the expression: print [1]
- In an equation for ‘main’: main = print [1]
-
-overloadedlistsfail01.hs:5:14:
- No instance for (IsList a0) arising from an overloaded list
- The type variable ‘a0’ is ambiguous
- Note: there are several potential instances:
- instance IsList Version -- Defined in ‘GHC.Exts’
- instance IsList [a] -- Defined in ‘GHC.Exts’
- In the first argument of ‘print’, namely ‘[1]’
- In the expression: print [1]
- In an equation for ‘main’: main = print [1]
-
-overloadedlistsfail01.hs:5:15:
- No instance for (Num (Item a0)) arising from the literal ‘1’
- The type variable ‘a0’ is ambiguous
- Note: there are several potential instances:
- instance Num Integer -- Defined in ‘GHC.Num’
- instance Num Double -- Defined in ‘GHC.Float’
- instance Num Float -- Defined in ‘GHC.Float’
- ...plus two others
- In the expression: 1
- In the first argument of ‘print’, namely ‘[1]’
- In the expression: print [1]
+ +overloadedlistsfail01.hs:5:8: error: + No instance for (Show a0) arising from a use of ‘print’ + The type variable ‘a0’ is ambiguous + Potential instances: + instance [safe] Show Version -- Defined in ‘Data.Version’ + instance Show a => Show (Maybe a) -- Defined in ‘GHC.Show’ + instance Show Ordering -- Defined in ‘GHC.Show’ + ...plus 23 others + (use -fprint-potential-instances to see them all) + In the expression: print [1] + In an equation for ‘main’: main = print [1] + +overloadedlistsfail01.hs:5:14: error: + No instance for (IsList a0) arising from an overloaded list + The type variable ‘a0’ is ambiguous + Potential instances: + instance IsList Version -- Defined in ‘GHC.Exts’ + instance IsList [a] -- Defined in ‘GHC.Exts’ + In the first argument of ‘print’, namely ‘[1]’ + In the expression: print [1] + In an equation for ‘main’: main = print [1] + +overloadedlistsfail01.hs:5:15: error: + No instance for (Num (Item a0)) arising from the literal ‘1’ + The type variable ‘a0’ is ambiguous + Potential instances: + instance Num Integer -- Defined in ‘GHC.Num’ + instance Num Double -- Defined in ‘GHC.Float’ + instance Num Float -- Defined in ‘GHC.Float’ + ...plus two others + (use -fprint-potential-instances to see them all) + In the expression: 1 + In the first argument of ‘print’, namely ‘[1]’ + In the expression: print [1] diff --git a/testsuite/tests/quotes/TH_localname.stderr b/testsuite/tests/quotes/TH_localname.stderr index a83c606eb4..76bfeea8a2 100644 --- a/testsuite/tests/quotes/TH_localname.stderr +++ b/testsuite/tests/quotes/TH_localname.stderr @@ -5,13 +5,14 @@ TH_localname.hs:3:11: error: Relevant bindings include y :: t0 (bound at TH_localname.hs:3:6) x :: t0 -> ExpQ (bound at TH_localname.hs:3:1) - Note: there are several potential instances: + Potential instances: instance (Lift a, Lift b) => Lift (Either a b) -- Defined in ‘Language.Haskell.TH.Syntax’ instance Lift a => Lift (Maybe a) -- Defined in ‘Language.Haskell.TH.Syntax’ instance Lift Int16 -- Defined in ‘Language.Haskell.TH.Syntax’ ...plus 24 others + (use -fprint-potential-instances to see them all) In the expression: lift y In the expression: [| y |] diff --git a/testsuite/tests/rebindable/rebindable6.stderr b/testsuite/tests/rebindable/rebindable6.stderr index 9e3dc0a5c7..b843f33bd7 100644 --- a/testsuite/tests/rebindable/rebindable6.stderr +++ b/testsuite/tests/rebindable/rebindable6.stderr @@ -9,7 +9,7 @@ rebindable6.hs:106:17: error: f :: IO a (bound at rebindable6.hs:104:17) test_do :: IO a -> IO (Maybe b) -> IO b (bound at rebindable6.hs:104:9) - Note: there is a potential instance available: + Potential instances: instance HasSeq (IO a -> IO b -> IO b) -- Defined at rebindable6.hs:52:18 In a stmt of a 'do' block: f @@ -28,7 +28,7 @@ rebindable6.hs:107:17: error: arising from a do statement (maybe you haven't applied a function to enough arguments?) The type variable ‘t1’ is ambiguous - Note: there is a potential instance available: + Potential instances: instance HasFail (String -> IO a) -- Defined at rebindable6.hs:57:18 In a stmt of a 'do' block: Just (b :: b) <- g @@ -52,7 +52,7 @@ rebindable6.hs:108:17: error: g :: IO (Maybe b) (bound at rebindable6.hs:104:19) test_do :: IO a -> IO (Maybe b) -> IO b (bound at rebindable6.hs:104:9) - Note: there is a potential instance available: + Potential instances: instance HasReturn (a -> IO a) -- Defined at rebindable6.hs:42:18 In a stmt of a 'do' block: return b In the expression: diff --git a/testsuite/tests/rename/should_fail/mc14.stderr b/testsuite/tests/rename/should_fail/mc14.stderr index 860d483ffe..3f52be33c6 100644 --- a/testsuite/tests/rename/should_fail/mc14.stderr +++ b/testsuite/tests/rename/should_fail/mc14.stderr @@ -1,14 +1,15 @@ -
-mc14.hs:14:16: error:
- No instance for (Functor t0) arising from a use of ‘fmap’
- The type variable ‘t0’ is ambiguous
- Note: there are several potential instances:
- instance Functor Maybe -- Defined in ‘GHC.Base’
- instance Functor IO -- Defined in ‘GHC.Base’
- instance Functor ((->) r) -- Defined in ‘GHC.Base’
- ...plus two others
- In the expression: fmap
- In a stmt of a monad comprehension: then group using f
- In the expression: [() | f <- functions, then group using f]
-
-mc14.hs:14:49: error: Variable not in scope: f :: [a] -> m (t0 a)
+ +mc14.hs:14:16: error: + No instance for (Functor t0) arising from a use of ‘fmap’ + The type variable ‘t0’ is ambiguous + Potential instances: + instance Functor Maybe -- Defined in ‘GHC.Base’ + instance Functor IO -- Defined in ‘GHC.Base’ + instance Functor ((->) r) -- Defined in ‘GHC.Base’ + ...plus two others + (use -fprint-potential-instances to see them all) + In the expression: fmap + In a stmt of a monad comprehension: then group using f + In the expression: [() | f <- functions, then group using f] + +mc14.hs:14:49: error: Variable not in scope: f :: [a] -> m (t0 a) diff --git a/testsuite/tests/typecheck/should_compile/holes2.stderr b/testsuite/tests/typecheck/should_compile/holes2.stderr index 4ce2e24aa4..392b69992d 100644 --- a/testsuite/tests/typecheck/should_compile/holes2.stderr +++ b/testsuite/tests/typecheck/should_compile/holes2.stderr @@ -1,19 +1,20 @@ -
-holes2.hs:3:5: warning:
- No instance for (Show a0) arising from a use of ‘show’
- The type variable ‘a0’ is ambiguous
- Note: there are several potential instances:
- instance Show a => Show (Maybe a) -- Defined in ‘GHC.Show’
- instance Show Ordering -- Defined in ‘GHC.Show’
- instance Show Integer -- Defined in ‘GHC.Show’
- ...plus 22 others
- In the expression: show _
- In an equation for ‘f’: f = show _
-
-holes2.hs:3:10: warning:
- Found hole: _ :: a0
- Where: ‘a0’ is an ambiguous type variable
- Relevant bindings include f :: String (bound at holes2.hs:3:1)
- In the first argument of ‘show’, namely ‘_’
- In the expression: show _
- In an equation for ‘f’: f = show _
+ +holes2.hs:3:5: warning: + No instance for (Show a0) arising from a use of ‘show’ + The type variable ‘a0’ is ambiguous + Potential instances: + instance Show a => Show (Maybe a) -- Defined in ‘GHC.Show’ + instance Show Ordering -- Defined in ‘GHC.Show’ + instance Show Integer -- Defined in ‘GHC.Show’ + ...plus 22 others + (use -fprint-potential-instances to see them all) + In the expression: show _ + In an equation for ‘f’: f = show _ + +holes2.hs:3:10: warning: + Found hole: _ :: a0 + Where: ‘a0’ is an ambiguous type variable + Relevant bindings include f :: String (bound at holes2.hs:3:1) + In the first argument of ‘show’, namely ‘_’ + In the expression: show _ + In an equation for ‘f’: f = show _ diff --git a/testsuite/tests/typecheck/should_fail/T4921.stderr b/testsuite/tests/typecheck/should_fail/T4921.stderr index a7267a26d3..091d461328 100644 --- a/testsuite/tests/typecheck/should_fail/T4921.stderr +++ b/testsuite/tests/typecheck/should_fail/T4921.stderr @@ -1,19 +1,19 @@ -
-T4921.hs:10:9:
- No instance for (C a0 b1) arising from a use of ‘f’
- The type variables ‘b1’, ‘a0’ are ambiguous
- Relevant bindings include x :: a0 (bound at T4921.hs:10:1)
- Note: there is a potential instance available:
- instance C Int Char -- Defined at T4921.hs:7:10
- In the first argument of ‘fst’, namely ‘f’
- In the expression: fst f
- In an equation for ‘x’: x = fst f
-
-T4921.hs:12:9:
- No instance for (C Int b0) arising from a use of ‘f’
- The type variable ‘b0’ is ambiguous
- Note: there is a potential instance available:
- instance C Int Char -- Defined at T4921.hs:7:10
- In the first argument of ‘fst’, namely ‘f’
- In the expression: fst f :: Int
- In an equation for ‘y’: y = fst f :: Int
+ +T4921.hs:10:9: error: + No instance for (C a0 b1) arising from a use of ‘f’ + The type variables ‘b1’, ‘a0’ are ambiguous + Relevant bindings include x :: a0 (bound at T4921.hs:10:1) + Potential instances: + instance C Int Char -- Defined at T4921.hs:7:10 + In the first argument of ‘fst’, namely ‘f’ + In the expression: fst f + In an equation for ‘x’: x = fst f + +T4921.hs:12:9: error: + No instance for (C Int b0) arising from a use of ‘f’ + The type variable ‘b0’ is ambiguous + Potential instances: + instance C Int Char -- Defined at T4921.hs:7:10 + In the first argument of ‘fst’, namely ‘f’ + In the expression: fst f :: Int + In an equation for ‘y’: y = fst f :: Int diff --git a/testsuite/tests/typecheck/should_fail/T5095.stderr b/testsuite/tests/typecheck/should_fail/T5095.stderr index 0cf88546a0..46667fb8f4 100644 --- a/testsuite/tests/typecheck/should_fail/T5095.stderr +++ b/testsuite/tests/typecheck/should_fail/T5095.stderr @@ -1,82 +1,14 @@ -T5095.hs:9:11: +T5095.hs:9:11: error: Overlapping instances for Eq a arising from a use of ‘==’ Matching instances: instance [overlappable] Show a => Eq a -- Defined at T5095.hs:5:31 - instance Eq a => Eq (Maybe a) -- Defined in ‘GHC.Base’ - instance Eq () -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b) => Eq (a, b) -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c) => Eq (a, b, c) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d) => Eq (a, b, c, d) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e) => Eq (a, b, c, d, e) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f) => - Eq (a, b, c, d, e, f) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g) => - Eq (a, b, c, d, e, f, g) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h) => - Eq (a, b, c, d, e, f, g, h) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i) => - Eq (a, b, c, d, e, f, g, h, i) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, - Eq j) => - Eq (a, b, c, d, e, f, g, h, i, j) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, - Eq j, Eq k) => - Eq (a, b, c, d, e, f, g, h, i, j, k) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, - Eq j, Eq k, Eq l) => - Eq (a, b, c, d, e, f, g, h, i, j, k, l) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, - Eq j, Eq k, Eq l, Eq m) => - Eq (a, b, c, d, e, f, g, h, i, j, k, l, m) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, - Eq j, Eq k, Eq l, Eq m, Eq n) => - Eq (a, b, c, d, e, f, g, h, i, j, k, l, m, n) - -- Defined in ‘GHC.Classes’ - instance (Eq a, Eq b, Eq c, Eq d, Eq e, Eq f, Eq g, Eq h, Eq i, - Eq j, Eq k, Eq l, Eq m, Eq n, Eq o) => - Eq (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o) - -- Defined in ‘GHC.Classes’ - instance Eq Bool -- Defined in ‘GHC.Classes’ - instance Eq Char -- Defined in ‘GHC.Classes’ - instance Eq Double -- Defined in ‘GHC.Classes’ - instance Eq Float -- Defined in ‘GHC.Classes’ - instance Eq Int -- Defined in ‘GHC.Classes’ - instance Eq Ordering -- Defined in ‘GHC.Classes’ - instance Eq Word -- Defined in ‘GHC.Classes’ - instance Eq a => Eq [a] -- Defined in ‘GHC.Classes’ - instance Eq integer-gmp-1.0.0.0:GHC.Integer.Type.BigNat - -- Defined in ‘integer-gmp-1.0.0.0:GHC.Integer.Type’ - instance Eq Integer - -- Defined in ‘integer-gmp-1.0.0.0:GHC.Integer.Type’ - instance Eq All -- Defined in ‘Data.Monoid’ - instance forall (k :: BOX) (f :: k -> *) (a :: k). - Eq (f a) => - Eq (Alt f a) - -- Defined in ‘Data.Monoid’ - instance Eq Any -- Defined in ‘Data.Monoid’ - instance Eq a => Eq (Dual a) -- Defined in ‘Data.Monoid’ - instance Eq a => Eq (First a) -- Defined in ‘Data.Monoid’ - instance Eq a => Eq (Last a) -- Defined in ‘Data.Monoid’ - instance Eq a => Eq (Product a) -- Defined in ‘Data.Monoid’ - instance Eq a => Eq (Sum a) -- Defined in ‘Data.Monoid’ - instance forall (k :: BOX) (s :: k). Eq (Proxy s) - -- Defined in ‘Data.Proxy’ instance (Eq a, Eq b) => Eq (Either a b) -- Defined in ‘Data.Either’ - instance (Ix i, Eq e) => Eq (Array i e) -- Defined in ‘GHC.Arr’ - instance Eq (STArray s i e) -- Defined in ‘GHC.Arr’ + instance Eq All -- Defined in ‘Data.Monoid’ + ...plus 35 others + ...plus one instance involving out-of-scope types + (use -fprint-potential-instances to see them all) (The choice depends on the instantiation of ‘a’ To pick the first instance above, use IncoherentInstances when compiling the other instance declarations) diff --git a/testsuite/tests/typecheck/should_fail/T5858.stderr b/testsuite/tests/typecheck/should_fail/T5858.stderr index 1378bae9c2..9c381d9bf6 100644 --- a/testsuite/tests/typecheck/should_fail/T5858.stderr +++ b/testsuite/tests/typecheck/should_fail/T5858.stderr @@ -1,9 +1,9 @@ -T5858.hs:11:7: +T5858.hs:11:7: error: No instance for (InferOverloaded ([t0], [t1])) arising from a use of ‘infer’ The type variables ‘t0’, ‘t1’ are ambiguous - Note: there is a potential instance available: + Potential instances: instance (t1 ~ String) => InferOverloaded (t1, t1) -- Defined at T5858.hs:8:10 In the expression: infer ([], []) diff --git a/testsuite/tests/typecheck/should_fail/T7857.stderr b/testsuite/tests/typecheck/should_fail/T7857.stderr index bc8fed9bf2..f413eb50f2 100644 --- a/testsuite/tests/typecheck/should_fail/T7857.stderr +++ b/testsuite/tests/typecheck/should_fail/T7857.stderr @@ -1,11 +1,11 @@ -T7857.hs:8:11: +T7857.hs:8:11: error: Could not deduce (PrintfType r0) arising from a use of ‘printf’ from the context: PrintfArg t bound by the inferred type of g :: PrintfArg t => t -> b at T7857.hs:8:1-21 The type variable ‘r0’ is ambiguous - Note: there are several potential instances: + Potential instances: instance [safe] (a ~ ()) => PrintfType (IO a) -- Defined in ‘Text.Printf’ instance [safe] (PrintfArg a, PrintfType r) => PrintfType (a -> r) diff --git a/testsuite/tests/typecheck/should_fail/tcfail008.stderr b/testsuite/tests/typecheck/should_fail/tcfail008.stderr index 2fc79b2220..db70a632f4 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail008.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail008.stderr @@ -1,18 +1,19 @@ -tcfail008.hs:3:5: +tcfail008.hs:3:5: error: No instance for (Num a0) arising from the literal ‘1’ The type variable ‘a0’ is ambiguous Relevant bindings include o :: [a0] (bound at tcfail008.hs:3:1) - Note: there are several potential instances: + Potential instances: instance Num Integer -- Defined in ‘GHC.Num’ instance Num Double -- Defined in ‘GHC.Float’ instance Num Float -- Defined in ‘GHC.Float’ ...plus two others + (use -fprint-potential-instances to see them all) In the first argument of ‘(:)’, namely ‘1’ In the expression: 1 : 2 In an equation for ‘o’: o = 1 : 2 -tcfail008.hs:3:7: +tcfail008.hs:3:7: error: No instance for (Num [a0]) arising from the literal ‘2’ In the second argument of ‘(:)’, namely ‘2’ In the expression: 1 : 2 diff --git a/testsuite/tests/typecheck/should_fail/tcfail040.stderr b/testsuite/tests/typecheck/should_fail/tcfail040.stderr index 923be56470..68e958ecab 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail040.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail040.stderr @@ -1,8 +1,8 @@ -tcfail040.hs:19:5: +tcfail040.hs:19:5: error: No instance for (ORD a0) arising from a use of ‘<<’ The type variable ‘a0’ is ambiguous - Note: there is a potential instance available: + Potential instances: instance ORD (a -> b) -- Defined at tcfail040.hs:17:10 In the first argument of ‘(===)’, namely ‘(<<)’ In the expression: (<<) === (<<) diff --git a/testsuite/tests/typecheck/should_fail/tcfail043.stderr b/testsuite/tests/typecheck/should_fail/tcfail043.stderr index a058d87ff8..fe24adc4e4 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail043.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail043.stderr @@ -1,12 +1,12 @@ -tcfail043.hs:38:17: +tcfail043.hs:38:17: error: No instance for (Ord_ a0) arising from a use of ‘gt’ The type variable ‘a0’ is ambiguous Relevant bindings include bs :: [a0] (bound at tcfail043.hs:38:8) a :: a0 (bound at tcfail043.hs:38:6) search :: a0 -> [a0] -> Bool (bound at tcfail043.hs:37:1) - Note: there is a potential instance available: + Potential instances: instance Ord_ Int -- Defined at tcfail043.hs:34:10 In the expression: gt (hd bs) a In the expression: @@ -21,14 +21,14 @@ tcfail043.hs:38:17: else if eq a (hd bs) then True else search a (tl bs) -tcfail043.hs:40:25: +tcfail043.hs:40:25: error: No instance for (Eq_ a0) arising from a use of ‘eq’ The type variable ‘a0’ is ambiguous Relevant bindings include bs :: [a0] (bound at tcfail043.hs:38:8) a :: a0 (bound at tcfail043.hs:38:6) search :: a0 -> [a0] -> Bool (bound at tcfail043.hs:37:1) - Note: there are several potential instances: + Potential instances: instance Eq_ Int -- Defined at tcfail043.hs:20:10 instance Eq_ a => Eq_ [a] -- Defined at tcfail043.hs:23:10 In the expression: eq a (hd bs) diff --git a/testsuite/tests/typecheck/should_fail/tcfail072.stderr b/testsuite/tests/typecheck/should_fail/tcfail072.stderr index c08bb58fb1..f3386f164b 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail072.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail072.stderr @@ -1,16 +1,18 @@ -tcfail072.hs:23:13: +tcfail072.hs:23:13: error: Could not deduce (Ord p0) arising from a use of ‘g’ from the context: (Ord p, Ord q) bound by the type signature for: - g :: (Ord p, Ord q) => AB p q -> Bool + g :: (Ord p, Ord q) => AB p q -> Bool at tcfail072.hs:22:6-38 The type variable ‘p0’ is ambiguous - Note: there are several potential instances: + Potential instances: instance Ord a => Ord (Maybe a) -- Defined in ‘GHC.Base’ instance Ord Ordering -- Defined in ‘GHC.Classes’ - instance Ord integer-gmp-1.0.0.0:GHC.Integer.Type.BigNat + instance Ord Integer -- Defined in ‘integer-gmp-1.0.0.0:GHC.Integer.Type’ - ...plus 23 others + ...plus 22 others + ...plus one instance involving out-of-scope types + (use -fprint-potential-instances to see them all) In the expression: g A In an equation for ‘g’: g (B _ _) = g A diff --git a/testsuite/tests/typecheck/should_fail/tcfail128.stderr b/testsuite/tests/typecheck/should_fail/tcfail128.stderr index 6d59560c82..4ad7273c0b 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail128.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail128.stderr @@ -1,9 +1,9 @@ -tcfail128.hs:18:16: +tcfail128.hs:18:16: error: No instance for (Data.Array.Base.MArray b0 FlatVector IO) arising from a use of ‘thaw’ The type variable ‘b0’ is ambiguous - Note: there is a potential instance available: + Potential instances: instance Data.Array.Base.MArray IOArray e IO -- Defined in ‘Data.Array.Base’ In a stmt of a 'do' block: v <- thaw tmp diff --git a/testsuite/tests/typecheck/should_fail/tcfail133.stderr b/testsuite/tests/typecheck/should_fail/tcfail133.stderr index dc9c96d2db..1869cea44b 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail133.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail133.stderr @@ -1,21 +1,22 @@ -tcfail133.hs:2:61: Warning: +tcfail133.hs:2:61: warning: -XDatatypeContexts is deprecated: It was widely considered a misfeature, and has been removed from the Haskell language. -tcfail133.hs:68:7: +tcfail133.hs:68:7: error: No instance for (Show r0) arising from a use of ‘show’ The type variable ‘r0’ is ambiguous - Note: there are several potential instances: + Potential instances: instance Show a => Show (Maybe a) -- Defined in ‘GHC.Show’ instance Show Ordering -- Defined in ‘GHC.Show’ instance Show Integer -- Defined in ‘GHC.Show’ ...plus 25 others + (use -fprint-potential-instances to see them all) In the expression: show In the expression: show $ add (One :@ Zero) (One :@ One) In an equation for ‘foo’: foo = show $ add (One :@ Zero) (One :@ One) -tcfail133.hs:68:14: +tcfail133.hs:68:14: error: No instance for (AddDigit (Zero :@ (One :@ One)) One r0) arising from a use of ‘add’ In the second argument of ‘($)’, namely diff --git a/testsuite/tests/typecheck/should_fail/tcfail181.stderr b/testsuite/tests/typecheck/should_fail/tcfail181.stderr index 787b62e330..3d3507f256 100644 --- a/testsuite/tests/typecheck/should_fail/tcfail181.stderr +++ b/testsuite/tests/typecheck/should_fail/tcfail181.stderr @@ -1,16 +1,17 @@ -tcfail181.hs:17:9: +tcfail181.hs:17:9: error: Could not deduce (Monad m0) arising from a use of ‘foo’ from the context: Monad m bound by the inferred type of wog :: Monad m => t -> Something (m Bool) e at tcfail181.hs:17:1-30 The type variable ‘m0’ is ambiguous - Note: there are several potential instances: + Potential instances: instance Monad Maybe -- Defined in ‘GHC.Base’ instance Monad IO -- Defined in ‘GHC.Base’ instance Monad ((->) r) -- Defined in ‘GHC.Base’ ...plus two others + (use -fprint-potential-instances to see them all) In the expression: foo In the expression: foo {bar = return True} In an equation for ‘wog’: wog x = foo {bar = return True} |