Opened 10 years ago

Closed 10 years ago

Last modified 46 years ago

#424 closed bug (Wont Fix)

can't compile Y-combinator

Reported by: sakai Owned by: nobody
Priority: normal Milestone:
Component: Compiler Version: 6.4
Keywords: Cc:
Operating System: Architecture:
Type of failure: Test Case:
Blocked By: Blocking:
Related Tickets: Differential Revisions:

Description

When I try to compile the following code with GHC-6.4,
ghc takes much time and seems not to terminate.

module Fix (fix) where

newtype T a = PsiInv{ psi :: T a -> a }

fix :: (a -> a) -> a
fix f = g (PsiInv g)
    where g x = f (psi x x)

Change History (1)

comment:1 Changed 10 years ago by simonpj

  • Status changed from assigned to closed
Logged In: YES 
user_id=50165

This is a known bug.  The easiest way to fix it is to add a 
step count to the simplifier, but that's still kind of 
unsatisfactory.   At the moment it'll stay as a known bug. If it 
starts to bite Real Programs we may have to think again.

See 
http://www.haskell.org/ghc/docs/latest/html/users_guide/bugs.
html#bugs-ghc
Note: See TracTickets for help on using tickets.