#8383: "tagToEnum# (0# ==# 1#) :: Bool" causes CASEFAIL in ghci
---------------------------------+----------------------------------
        Reporter:  rwbarton      |            Owner:
            Type:  bug           |           Status:  new
        Priority:  normal        |        Milestone:
       Component:  GHCi          |          Version:  7.7
      Resolution:                |         Keywords:
Operating System:  Linux         |     Architecture:  x86_64 (amd64)
 Type of failure:  None/Unknown  |       Difficulty:  Unknown
       Test Case:                |       Blocked By:
        Blocking:                |  Related Tickets:
---------------------------------+----------------------------------

Comment (by rwbarton):

 It seems that the issue is in the bytecode generator for `tagToEnum#`,
 which has been wrong since at least ghc 6.8.2 and probably since it was
 added in 2001. However, an application of `tagToEnum#` to a constant
 apparently gets constant-folded away before the interpreter sees it, which
 is probably why nobody ever noticed before `tagToEnum#` became used in
 derived Eq instances.

-- 
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8383#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
ghc-tickets mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/ghc-tickets

Reply via email to