[GHC] #10577: Use empty cases where appropriate when deriving instances for empty types
GHC
ghc-devs at haskell.org
Fri Sep 29 13:15:38 UTC 2017
#10577: Use empty cases where appropriate when deriving instances for empty types
-------------------------------------+-------------------------------------
Reporter: rwbarton | Owner: (none)
Type: bug | Status: patch
Priority: normal | Milestone:
Component: Compiler | Version: 7.11
Resolution: | Keywords: deriving
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: #13117, #7401 | Differential Rev(s): Phab:D4047
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by RyanGlScott):
I'm not sure if you're asking me to add something here or in the Diff. If
the latter, are you asking for a test case to see if something like this
evaluates to `True`?
{{{#!hs
{-# LANGUAGE EmptyDataDeriving #-}
module Main where
import Data.Function
data Foo deriving Eq
foo1 :: Foo
foo1 = fix id
foo2 :: Foo
foo2 = let x = y
y = x
in y
main :: IO ()
main = print (foo1 == foo2)
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10577#comment:9>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list