summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/T3323.stderr
blob: 1e77e05318dace4c13a7d32a3b690c2dd66388be (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34

T3323.hs:18:7: error:
    • Could not deduce (GHC.IO.Device.RawIO dev0)
      from the context: (GHC.IO.Device.RawIO dev,
                         GHC.IO.Device.IODevice dev, GHC.IO.BufferedIO.BufferedIO dev,
                         base-4.16.0.0:Data.Typeable.Internal.Typeable dev)
        bound by a pattern with constructor:
                   Handle__ :: forall dev enc_state dec_state.
                               (GHC.IO.Device.RawIO dev, GHC.IO.Device.IODevice dev,
                                GHC.IO.BufferedIO.BufferedIO dev,
                                base-4.16.0.0:Data.Typeable.Internal.Typeable dev) =>
                               dev
                               -> HandleType
                               -> GHC.IORef.IORef (GHC.IO.Buffer.Buffer GHC.Word.Word8)
                               -> BufferMode
                               -> GHC.IORef.IORef (dec_state, GHC.IO.Buffer.Buffer GHC.Word.Word8)
                               -> GHC.IORef.IORef (GHC.IO.Buffer.Buffer GHC.IO.Buffer.CharBufElem)
                               -> GHC.IORef.IORef (BufferList GHC.IO.Buffer.CharBufElem)
                               -> Maybe (GHC.IO.Encoding.Types.TextEncoder enc_state)
                               -> Maybe (GHC.IO.Encoding.Types.TextDecoder dec_state)
                               -> Maybe GHC.IO.Encoding.Types.TextEncoding
                               -> Newline
                               -> Newline
                               -> Maybe (GHC.MVar.MVar Handle__)
                               -> Handle__,
                 in a case alternative
        at T3323.hs:18:7-28
      The type variable ‘dev0’ is ambiguous
    • In a record update at field ‘haDevice’,
      with type constructor ‘Handle__’,
      data constructor ‘Handle__’
      and existential variables ‘dev’, ‘enc_state’, ‘dec_state’.
      In the expression: h {haDevice = undefined}
      In an equation for ‘f’: f h = h {haDevice = undefined}