summaryrefslogtreecommitdiff
path: root/testsuite/tests/typecheck/should_fail/tcfail072.stderr
blob: c916c92df135bfc58c6409afe33236c336659f92 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17

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 :: forall p q. (Ord p, Ord q) => AB p q -> Bool
        at tcfail072.hs:22:1-38
      The type variable ‘p0’ is ambiguous
      These potential instances exist:
        instance Ord Ordering -- Defined in ‘GHC.Classes’
        instance Ord Integer -- Defined in ‘GHC.Num.Integer’
        instance Ord () -- Defined in ‘GHC.Classes’
        ...plus N others
        ...plus N instances 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