[GHC] #12476: Error building HList
GHC
ghc-devs at haskell.org
Thu Sep 1 16:25:20 UTC 2016
#12476: Error building HList
-------------------------------------+-------------------------------------
Reporter: DanielWaterworth | Owner:
Type: bug | Status: infoneeded
Priority: normal | Milestone: 8.0.2
Component: Compiler | Version: 8.0.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Changes (by bgamari):
* status: new => infoneeded
Comment:
Well, this doesn't quite compile yet but then again it also doesn't
compile with 7.10. DanielWaterworth, can you confirm that this is
expected?
{{{
Data/HList/Dredge.hs:78:27: error:
• Ambiguous type variables ‘x1’, ‘k1’, ‘l1’ arising from a use of
‘dredge’
prevents the constraint ‘(EnsureLabel
x1 (Label l1))’ from being solved.
Relevant bindings include
label :: x1 (bound at Data/HList/Dredge.hs:78:9)
dredge' :: x1 -> p1 a1 (f1 a1) -> p1 s1 (f1 s1)
(bound at Data/HList/Dredge.hs:78:1)
Probable fix: use a type annotation to specify what ‘x1’, ‘k1’, ‘l1’
should be.
These potential instances exist:
instance forall k (x :: k). EnsureLabel (Label x) (Label x)
-- Defined at Data/HList/Labelable.hs:204:10
instance forall k (x :: k). EnsureLabel (Proxy x) (Label x)
-- Defined at Data/HList/Labelable.hs:207:10
...plus one instance involving out-of-scope types
(use -fprint-potential-instances to see them all)
• In the first argument of ‘isSimple’, namely ‘(dredge label)’
In the expression: isSimple (dredge label)
In an equation for ‘dredge'’:
dredge' label = isSimple (dredge label)
Data/HList/Dredge.hs:90:29: error:
• Ambiguous type variables ‘x0’, ‘k0’, ‘l0’ arising from a use of
‘dredgeND’
prevents the constraint ‘(EnsureLabel
x0 (Label l0))’ from being solved.
Relevant bindings include
label :: x0 (bound at Data/HList/Dredge.hs:90:11)
dredgeND' :: x0 -> p0 a0 (f0 a0) -> p0 s0 (f0 s0)
(bound at Data/HList/Dredge.hs:90:1)
Probable fix: use a type annotation to specify what ‘x0’, ‘k0’, ‘l0’
should be.
These potential instances exist:
instance forall k (x :: k). EnsureLabel (Label x) (Label x)
-- Defined at Data/HList/Labelable.hs:204:10
instance forall k (x :: k). EnsureLabel (Proxy x) (Label x)
-- Defined at Data/HList/Labelable.hs:207:10
...plus one instance involving out-of-scope types
(use -fprint-potential-instances to see them all)
• In the first argument of ‘isSimple’, namely ‘(dredgeND label)’
In the expression: isSimple (dredgeND label)
In an equation for ‘dredgeND'’:
dredgeND' label = isSimple (dredgeND label)
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/12476#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list