blob: 4cf3b153fd79301bf7aa104cf65904f0c195d6f4 (
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
|
T4485.hs:50:15: error:
• Overlapping instances for EmbedAsChild
(IdentityT IO) (XMLGenT m0 (XML m0))
arising from a use of ‘asChild’
Matching instances:
instance [overlapping] (EmbedAsChild m c, m1 ~ m) =>
EmbedAsChild m (XMLGenT m1 c)
-- Defined at T4485.hs:28:30
instance [overlapping] EmbedAsChild
(IdentityT IO) (XMLGenT Identity ())
-- Defined at T4485.hs:45:30
(The choice depends on the instantiation of ‘m0’
To pick the first instance above, use IncoherentInstances
when compiling the other instance declarations)
• In the expression: asChild $ (genElement "foo")
In an equation for ‘asChild’:
asChild b = asChild $ (genElement "foo")
In the instance declaration for
‘EmbedAsChild (IdentityT IO) FooBar’
T4485.hs:50:26: error:
• Ambiguous type variable ‘m0’ arising from a use of ‘genElement’
prevents the constraint ‘(XMLGen m0)’ from being solved.
Probable fix: use a type annotation to specify what ‘m0’ should be.
These potential instance exist:
instance XMLGen (IdentityT m) -- Defined at T4485.hs:37:10
• In the second argument of ‘($)’, namely ‘(genElement "foo")’
In the expression: asChild $ (genElement "foo")
In an equation for ‘asChild’:
asChild b = asChild $ (genElement "foo")
|