Commit cf6e6569 authored by thomie's avatar thomie
Browse files

Testsuite: remove Windows CR [skip ci]

parent 9cdde381
T5380.hs:7:27: error:
• Couldn't match expected type ‘Bool’ with actual type ‘not_bool’
‘not_bool’ is a rigid type variable bound by
the type signature for:
testB :: forall not_bool not_unit.
not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:6:1-49
• In the expression: b
In the expression: proc () -> if b then f -< () else f -< ()
In an equation for ‘testB’:
testB b f = proc () -> if b then f -< () else f -< ()
• Relevant bindings include
b :: not_bool (bound at T5380.hs:7:7)
testB :: not_bool -> (() -> ()) -> () -> not_unit
(bound at T5380.hs:7:1)
T5380.hs:7:34: error:
• Couldn't match type ‘not_unit’ with ‘()’
‘not_unit’ is a rigid type variable bound by
the type signature for:
testB :: forall not_bool not_unit.
not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:6:1-49
Expected type: () -> not_unit
Actual type: () -> ()
• In the expression: f
In the command: f -< ()
In the expression: proc () -> if b then f -< () else f -< ()
• Relevant bindings include
testB :: not_bool -> (() -> ()) -> () -> not_unit
(bound at T5380.hs:7:1)
T5380.hs:7:27: error:
• Couldn't match expected type ‘Bool’ with actual type ‘not_bool’
‘not_bool’ is a rigid type variable bound by
the type signature for:
testB :: forall not_bool not_unit.
not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:6:1-49
• In the expression: b
In the expression: proc () -> if b then f -< () else f -< ()
In an equation for ‘testB’:
testB b f = proc () -> if b then f -< () else f -< ()
• Relevant bindings include
b :: not_bool (bound at T5380.hs:7:7)
testB :: not_bool -> (() -> ()) -> () -> not_unit
(bound at T5380.hs:7:1)
T5380.hs:7:34: error:
• Couldn't match type ‘not_unit’ with ‘()’
‘not_unit’ is a rigid type variable bound by
the type signature for:
testB :: forall not_bool not_unit.
not_bool -> (() -> ()) -> () -> not_unit
at T5380.hs:6:1-49
Expected type: () -> not_unit
Actual type: () -> ()
• In the expression: f
In the command: f -< ()
In the expression: proc () -> if b then f -< () else f -< ()
• Relevant bindings include
testB :: not_bool -> (() -> ()) -> () -> not_unit
(bound at T5380.hs:7:1)
T11241.hs:5:21: warning: [-Wpartial-type-signatures (in -Wdefault)]
• Found type wildcard ‘_’ standing for ‘*’
• In the type signature: foo :: forall (a :: _). a -> a
T11241.hs:5:21: warning: [-Wpartial-type-signatures (in -Wdefault)]
• Found type wildcard ‘_’ standing for ‘*’
• In the type signature: foo :: forall (a :: _). a -> a
T7148.hs:27:40: error:
• Couldn't match type ‘b’ with ‘Tagged a b’
arising from the coercion of the method ‘iso2’
from type ‘forall b. SameType b () -> SameType b b’
to type ‘forall b. SameType b () -> SameType b (Tagged a b)’
‘b’ is a rigid type variable bound by
the deriving clause for ‘IsoUnit (Tagged a b)’ at T7148.hs:27:40-46
• When deriving the instance for (IsoUnit (Tagged a b))
T7148.hs:27:40: error:
• Couldn't match type ‘b’ with ‘Tagged a b’
arising from the coercion of the method ‘iso1’
from type ‘forall b. SameType () b -> SameType b b’
to type ‘forall b. SameType () b -> SameType (Tagged a b) b’
‘b’ is a rigid type variable bound by
the deriving clause for ‘IsoUnit (Tagged a b)’ at T7148.hs:27:40-46
• When deriving the instance for (IsoUnit (Tagged a b))
T7148.hs:27:40: error:
• Couldn't match type ‘b’ with ‘Tagged a b’
arising from the coercion of the method ‘iso2’
from type ‘forall b. SameType b () -> SameType b b’
to type ‘forall b. SameType b () -> SameType b (Tagged a b)’
‘b’ is a rigid type variable bound by
the deriving clause for ‘IsoUnit (Tagged a b)’ at T7148.hs:27:40-46
• When deriving the instance for (IsoUnit (Tagged a b))
T7148.hs:27:40: error:
• Couldn't match type ‘b’ with ‘Tagged a b’
arising from the coercion of the method ‘iso1’
from type ‘forall b. SameType () b -> SameType b b’
to type ‘forall b. SameType () b -> SameType (Tagged a b) b’
‘b’ is a rigid type variable bound by
the deriving clause for ‘IsoUnit (Tagged a b)’ at T7148.hs:27:40-46
• When deriving the instance for (IsoUnit (Tagged a b))
T7148a.hs:19:50: error:
• Couldn't match representation of type ‘b’
with that of ‘Result a b’
arising from the coercion of the method ‘coerce’
from type ‘forall b. Proxy b -> a -> Result a b’
to type ‘forall b.
Proxy b -> IS_NO_LONGER a -> Result (IS_NO_LONGER a) b’
‘b’ is a rigid type variable bound by
the type Proxy b -> a -> Result a b at T7148a.hs:19:50-56
• When deriving the instance for (Convert (IS_NO_LONGER a))
T7148a.hs:19:50: error:
• Couldn't match representation of type ‘b’
with that of ‘Result a b’
arising from the coercion of the method ‘coerce’
from type ‘forall b. Proxy b -> a -> Result a b’
to type ‘forall b.
Proxy b -> IS_NO_LONGER a -> Result (IS_NO_LONGER a) b’
‘b’ is a rigid type variable bound by
the type Proxy b -> a -> Result a b at T7148a.hs:19:50-56
• When deriving the instance for (Convert (IS_NO_LONGER a))
T3169.hs:13:22: error:
• Couldn't match type ‘elt’ with ‘Map b elt’
‘elt’ is a rigid type variable bound by
the type signature for:
lookup :: forall elt. (a, b) -> Map (a, b) elt -> Maybe elt
at T3169.hs:12:3-8
Expected type: Map a (Map b elt)
Actual type: Map (a, b) elt
• In the second argument of ‘lookup’, namely ‘m’
In the expression: lookup a m :: Maybe (Map b elt)
In the expression:
case lookup a m :: Maybe (Map b elt) of {
Just (m2 :: Map b elt) -> lookup b m2 :: Maybe elt }
• Relevant bindings include
m :: Map (a, b) elt (bound at T3169.hs:12:17)
b :: b (bound at T3169.hs:12:13)
lookup :: (a, b) -> Map (a, b) elt -> Maybe elt
(bound at T3169.hs:12:3)
T3169.hs:13:22: error:
• Couldn't match type ‘elt’ with ‘Map b elt’
‘elt’ is a rigid type variable bound by
the type signature for:
lookup :: forall elt. (a, b) -> Map (a, b) elt -> Maybe elt
at T3169.hs:12:3-8
Expected type: Map a (Map b elt)
Actual type: Map (a, b) elt
• In the second argument of ‘lookup’, namely ‘m’
In the expression: lookup a m :: Maybe (Map b elt)
In the expression:
case lookup a m :: Maybe (Map b elt) of {
Just (m2 :: Map b elt) -> lookup b m2 :: Maybe elt }
• Relevant bindings include
m :: Map (a, b) elt (bound at T3169.hs:12:17)
b :: b (bound at T3169.hs:12:13)
lookup :: (a, b) -> Map (a, b) elt -> Maybe elt
(bound at T3169.hs:12:3)
T7558.hs:8:4: error:
• Couldn't match type ‘a’ with ‘Maybe a’
‘a’ is a rigid type variable bound by
the type signature for:
f :: forall a. T a a -> Bool
at T7558.hs:7:1-18
Inaccessible code in
a pattern with constructor:
MkT :: forall a b. a ~ Maybe b => a -> Maybe b -> T a b,
in an equation for ‘f’
• In the pattern: MkT x y
In an equation for ‘f’: f (MkT x y) = [x, y] `seq` True
• Relevant bindings include
f :: T a a -> Bool (bound at T7558.hs:8:1)
T7558.hs:8:4: error:
• Couldn't match type ‘a’ with ‘Maybe a’
‘a’ is a rigid type variable bound by
the type signature for:
f :: forall a. T a a -> Bool
at T7558.hs:7:1-18
Inaccessible code in
a pattern with constructor:
MkT :: forall a b. a ~ Maybe b => a -> Maybe b -> T a b,
in an equation for ‘f’
• In the pattern: MkT x y
In an equation for ‘f’: f (MkT x y) = [x, y] `seq` True
• Relevant bindings include
f :: T a a -> Bool (bound at T7558.hs:8:1)
gadt-escape1.hs:19:58: error:
• Couldn't match type ‘t’ with ‘ExpGADT Int’
‘t’ is untouchable
inside the constraints: t1 ~ Int
bound by a pattern with constructor: ExpInt :: Int -> ExpGADT Int,
in a case alternative
at gadt-escape1.hs:19:43-50
‘t’ is a rigid type variable bound by
the inferred type of weird1 :: t at gadt-escape1.hs:19:1-58
Possible fix: add a type signature for ‘weird1’
Expected type: t
Actual type: ExpGADT t1
• In the expression: a
In a case alternative: Hidden (ExpInt _) a -> a
In the expression:
case (hval :: Hidden) of { Hidden (ExpInt _) a -> a }
• Relevant bindings include
weird1 :: t (bound at gadt-escape1.hs:19:1)
gadt-escape1.hs:19:58: error:
• Couldn't match type ‘t’ with ‘ExpGADT Int’
‘t’ is untouchable
inside the constraints: t1 ~ Int
bound by a pattern with constructor: ExpInt :: Int -> ExpGADT Int,
in a case alternative
at gadt-escape1.hs:19:43-50
‘t’ is a rigid type variable bound by
the inferred type of weird1 :: t at gadt-escape1.hs:19:1-58
Possible fix: add a type signature for ‘weird1’
Expected type: t
Actual type: ExpGADT t1
• In the expression: a
In a case alternative: Hidden (ExpInt _) a -> a
In the expression:
case (hval :: Hidden) of { Hidden (ExpInt _) a -> a }
• Relevant bindings include
weird1 :: t (bound at gadt-escape1.hs:19:1)
rw.hs:14:47: error:
• Couldn't match expected type ‘a’ with actual type ‘Int’
‘a’ is a rigid type variable bound by
the type signature for:
writeInt :: forall a. T a -> IORef a -> IO ()
at rw.hs:12:1-34
• 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)
• Relevant bindings include
ref :: IORef a (bound at rw.hs:13:12)
v :: T a (bound at rw.hs:13:10)
writeInt :: T a -> IORef a -> IO () (bound at rw.hs:13:1)
rw.hs:19:43: error:
• Couldn't match type ‘a’ with ‘Bool’
‘a’ is a rigid type variable bound by
the type signature for:
readBool :: forall a. T a -> IORef a -> IO ()
at rw.hs:16:1-34
Expected type: a -> IO ()
Actual type: Bool -> IO ()
• In the second argument of ‘(>>=)’, namely ‘(print . not)’
In the expression: readIORef ref >>= (print . not)
In a case alternative: ~(Lb x) -> readIORef ref >>= (print . not)
• Relevant bindings include
ref :: IORef a (bound at rw.hs:17:12)
v :: T a (bound at rw.hs:17:10)
readBool :: T a -> IORef a -> IO () (bound at rw.hs:17:1)
rw.hs:14:47: error:
• Couldn't match expected type ‘a’ with actual type ‘Int’
‘a’ is a rigid type variable bound by
the type signature for:
writeInt :: forall a. T a -> IORef a -> IO ()
at rw.hs:12:1-34
• 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)
• Relevant bindings include
ref :: IORef a (bound at rw.hs:13:12)
v :: T a (bound at rw.hs:13:10)
writeInt :: T a -> IORef a -> IO () (bound at rw.hs:13:1)
rw.hs:19:43: error:
• Couldn't match type ‘a’ with ‘Bool’
‘a’ is a rigid type variable bound by
the type signature for:
readBool :: forall a. T a -> IORef a -> IO ()
at rw.hs:16:1-34
Expected type: a -> IO ()
Actual type: Bool -> IO ()
• In the second argument of ‘(>>=)’, namely ‘(print . not)’
In the expression: readIORef ref >>= (print . not)
In a case alternative: ~(Lb x) -> readIORef ref >>= (print . not)
• Relevant bindings include
ref :: IORef a (bound at rw.hs:17:12)
v :: T a (bound at rw.hs:17:10)
readBool :: T a -> IORef a -> IO () (bound at rw.hs:17:1)
(12,12,8)
(93,63,0)
(15,13,8)
(10,10,8)
(12,12,8)
(93,63,0)
(15,13,8)
(10,10,8)
Defer01.hs:11:40: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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 ','
Defer01.hs:14:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Int’ with actual type ‘Char’
• In the expression: 'p'
In an equation for ‘a’: a = 'p'
Defer01.hs:18:7: warning: [-Wdeferred-type-errors (in -Wdefault)]
• No instance for (Eq B) arising from a use of ‘==’
• In the expression: x == x
In an equation for ‘b’: b x = x == x
Defer01.hs:25:1: warning: [-Woverlapping-patterns (in -Wdefault)]
Pattern match has inaccessible right hand side
In an equation for ‘c’: c (C2 x) = ...
Defer01.hs:25:4: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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
Defer01.hs:28:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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
Defer01.hs:31:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Char -> t’ with actual type ‘Char’
• 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'
• Relevant bindings include
f :: t (bound at Defer01.hs:31:1)
Defer01.hs:34:8: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Char’ with actual type ‘a’
‘a’ is a rigid type variable bound by
the type signature for:
h :: forall a. a -> (Char, Char)
at Defer01.hs:33:1-21
• In the expression: x
In the expression: (x, 'c')
In an equation for ‘h’: h x = (x, 'c')
• Relevant bindings include
x :: a (bound at Defer01.hs:34:3)
h :: a -> (Char, Char)
(bound at Defer01.hs:34:1)
Defer01.hs:39:17: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Bool’ with actual type ‘T a’
• In the first argument of ‘not’, namely ‘(K a)’
In the expression: (not (K a))
In the expression: seq (not (K a)) ()
• Relevant bindings include
a :: a (bound at Defer01.hs:39:3)
i :: a -> () (bound at Defer01.hs:39:1)
Defer01.hs:43:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• No instance for (MyClass a1) arising from a use of ‘myOp’
• In the expression: myOp 23
In an equation for ‘j’: j = myOp 23
Defer01.hs:43:10: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Ambiguous type variable ‘a1’ arising from the literal ‘23’
prevents the constraint ‘(Num a1)’ from being solved.
Probable fix: use a type annotation to specify what ‘a1’ should be.
These potential instances exist:
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
Defer01.hs:45:1: warning: [-Wdeferred-type-errors (in -Wdefault)]
Couldn't match type ‘Int’ with ‘Bool’
Inaccessible code in
the type signature for:
k :: Int ~ Bool => Int -> Bool
Defer01.hs:45:6: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match type ‘Int’ with ‘Bool’
Inaccessible code in
the type signature for:
k :: Int ~ Bool => Int -> Bool
• In the ambiguity check for ‘k’
To defer the ambiguity check to use sites, enable AllowAmbiguousTypes
In the type signature: k :: (Int ~ Bool) => Int -> Bool
Defer01.hs:46:1: warning: [-Woverlapping-patterns (in -Wdefault)]
Pattern match is redundant
In an equation for ‘k’: k x = ...
Defer01.hs:49:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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'
In an equation for ‘l’: l = putChar >> putChar 'p'
*** Exception: 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: 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: Defer01.hs:18:7: 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))’
In the expression: print (c (C2 True))
*** Exception: 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: Defer01.hs:31:5: error:
• Couldn't match expected type ‘Char -> t’ with actual type ‘Char’
• 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'
• Relevant bindings include
f :: t (bound at Defer01.hs:31:1)
(deferred type error)
*** Exception: 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 :: forall a. a -> (Char, Char)
at Defer01.hs:33:1-21
• In the expression: x
In the expression: (x, 'c')
In an equation for ‘h’: h x = (x, 'c')
• Relevant bindings include
x :: a (bound at Defer01.hs:34:3)
h :: a -> (Char, Char)
(bound at Defer01.hs:34:1)
(deferred type error)
*** Exception: Defer01.hs:39:17: error:
• Couldn't match expected type ‘Bool’ with actual type ‘T a’
• In the first argument of ‘not’, namely ‘(K a)’
In the expression: (not (K a))
In the expression: seq (not (K a)) ()
• Relevant bindings include
a :: a (bound at Defer01.hs:39:3)
i :: a -> () (bound at Defer01.hs:39:1)
(deferred type error)
*** Exception: 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 type ‘Int’ with ‘Bool’ arising from a use of ‘k’
• 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: 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'
In an equation for ‘l’: l = putChar >> putChar 'p'
(deferred type error)
Defer01.hs:11:40: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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 ','
Defer01.hs:14:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Int’ with actual type ‘Char’
• In the expression: 'p'
In an equation for ‘a’: a = 'p'
Defer01.hs:18:7: warning: [-Wdeferred-type-errors (in -Wdefault)]
• No instance for (Eq B) arising from a use of ‘==’
• In the expression: x == x
In an equation for ‘b’: b x = x == x
Defer01.hs:25:1: warning: [-Woverlapping-patterns (in -Wdefault)]
Pattern match has inaccessible right hand side
In an equation for ‘c’: c (C2 x) = ...
Defer01.hs:25:4: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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
Defer01.hs:28:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• 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
Defer01.hs:31:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Char -> t’ with actual type ‘Char’
• 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'
• Relevant bindings include
f :: t (bound at Defer01.hs:31:1)
Defer01.hs:34:8: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Char’ with actual type ‘a’
‘a’ is a rigid type variable bound by
the type signature for:
h :: forall a. a -> (Char, Char)
at Defer01.hs:33:1-21
• In the expression: x
In the expression: (x, 'c')
In an equation for ‘h’: h x = (x, 'c')
• Relevant bindings include
x :: a (bound at Defer01.hs:34:3)
h :: a -> (Char, Char)
(bound at Defer01.hs:34:1)
Defer01.hs:39:17: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Couldn't match expected type ‘Bool’ with actual type ‘T a’
• In the first argument of ‘not’, namely ‘(K a)’
In the expression: (not (K a))
In the expression: seq (not (K a)) ()
• Relevant bindings include
a :: a (bound at Defer01.hs:39:3)
i :: a -> () (bound at Defer01.hs:39:1)
Defer01.hs:43:5: warning: [-Wdeferred-type-errors (in -Wdefault)]
• No instance for (MyClass a1) arising from a use of ‘myOp’
• In the expression: myOp 23
In an equation for ‘j’: j = myOp 23
Defer01.hs:43:10: warning: [-Wdeferred-type-errors (in -Wdefault)]
• Ambiguous type variable ‘a1’ arising from the literal ‘23’
prevents the constraint ‘(Num a1)’ from being solved.
Probable fix: use a type annotation to specify what ‘a1’ should be.
These potential instances exist:
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
Defer01.hs:45:1: warning: [-Wdeferred-type-errors (in -Wdefault)]
Couldn't match type ‘Int’ with ‘Bool’
Inaccessible code in
the type signature for:
k :: Int ~ Bool => Int -> Bool