[GHC] #11084: Some type families don't reduce with :kind!
GHC
ghc-devs at haskell.org
Sat Nov 14 02:12:09 UTC 2015
#11084: Some type families don't reduce with :kind!
-------------------------------------+-------------------------------------
Reporter: goldfire | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.10.2
Keywords: | Operating System: Unknown/Multiple
Architecture: | Type of failure: None/Unknown
Unknown/Multiple |
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
Sadly, I'm unable to reproduce this without `singletons`. :(
Observe:
{{{
> ghci
GHCi, version 7.10.2: http://www.haskell.org/ghc/ :? for help
Prelude> import Data.Promotion.Prelude -- singletons-2.0.1
Prelude Data.Promotion.Prelude> :kind! Lookup 'True '[ '(True, True) ]
Lookup 'True '[ '(True, True) ] :: Maybe Bool
= Data.Singletons.Prelude.List.Case_1628035408
'True
'True
'True
'[]
(Data.Singletons.Apply (Data.Singletons.Apply (:==$) 'True) 'True)
Prelude Data.Promotion.Prelude> :kind! Lookup 'True '[ '(True, True) ]
Lookup 'True '[ '(True, True) ] :: Maybe Bool
= JustSym1 'True
}}}
Note that the exact same command run twice yields different results. I
tried peeking at `-ddump-tc-trace` but got nothing of use.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11084>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list