[GHC] #15677: Valid hole fits and GADT type variable names
GHC
ghc-devs at haskell.org
Wed Dec 5 16:28:06 UTC 2018
#15677: Valid hole fits and GADT type variable names
-------------------------------------+-------------------------------------
Reporter: RyanGlScott | Owner: (none)
Type: bug | Status: new
Priority: normal | Milestone: 8.8.1
Component: Compiler | Version: 8.6.1
Resolution: | Keywords: TypedHoles,
| GADTs
Operating System: Unknown/Multiple | Architecture:
Type of failure: Poor/confusing | Unknown/Multiple
error message | Test Case:
Blocked By: | Blocking:
Related Tickets: #9091 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by Tritlo):
Well, at least the situation for #9091 is a bit better now, with
constraints shown by default:
{{{
tritlo at nietzsche:~/Code$ ghc t9091.hs -XGADTs
[1 of 1] Compiling T9091 ( t9091.hs, t9091.o )
t9091.hs:7:9: error:
• Found hole: _ :: Int
• In the expression: _
In an equation for ‘h’: h Y x = _
• Relevant bindings include
x :: a (bound at t9091.hs:7:5)
h :: X a -> a -> a (bound at t9091.hs:7:1)
Constraints include a ~ Int (from t9091.hs:7:3)
Valid hole fits include
x :: a (bound at t9091.hs:7:5)
maxBound :: forall a. Bounded a => a
with maxBound @Int
(imported from ‘Prelude’ at t9091.hs:1:8-12
(and originally defined in ‘GHC.Enum’))
minBound :: forall a. Bounded a => a
with minBound @Int
(imported from ‘Prelude’ at t9091.hs:1:8-12
(and originally defined in ‘GHC.Enum’))
|
7 | h Y x = _
}}}
but this is still an issue.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/15677#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list