[GHC] #12921: initTc: unsolved constraints
GHC
ghc-devs at haskell.org
Mon Jul 10 19:51:24 UTC 2017
#12921: initTc: unsolved constraints
-------------------------------------+-------------------------------------
Reporter: jlp | Owner: (none)
Type: bug | Status: closed
Priority: normal | Milestone: 8.2.1
Component: Compiler (Type | Version: 8.0.1
checker) |
Resolution: fixed | Keywords:
Operating System: MacOS X | Architecture: x86_64
| (amd64)
Type of failure: Compile-time | Test Case:
crash or panic | typecheck/should_fail/T12921
Blocked By: | Blocking:
Related Tickets: #13106 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by RyanGlScott):
gnezdo, I can confirm that your code no longer panics with GHC 8.2:
{{{
$ /opt/ghc/8.2.1/bin/ghci Bug.hs
GHCi, version 8.2.0.20170704: http://www.haskell.org/ghc/ :? for help
Loaded GHCi configuration from /home/rgscott/.ghci
[1 of 1] Compiling Main ( Bug.hs, interpreted )
Ok, 1 module loaded.
λ> Log2 (2 :: GHC.TypeLits.KnownNat)
<interactive>:1:1: error:
Data constructor not in scope: Log2 :: t0 -> t1
<interactive>:1:12: error:
• Expecting one more argument to ‘KnownNat’
Expected a type, but ‘KnownNat’ has kind ‘Nat -> Constraint’
• In an expression type signature: KnownNat
In the first argument of ‘Log2’, namely ‘(2 :: KnownNat)’
In the expression: Log2 (2 :: KnownNat)
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/12921#comment:11>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list