Opened 12 years ago

Closed 12 years ago

Last modified 48 years ago

#425 closed bug (Fixed)

Template Haskell: reification of data types w/o constructors

Reported by: wthaller Owned by: nobody
Priority: normal Milestone:
Component: Template Haskell Version: 6.4
Keywords: Cc:
Operating System: Architecture:
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


Reifying data types without constructors works in --make mode, but 
causes an exception in TcSplice.lhs in one-shot compilation.

Attachments (1) (522 bytes) - added by wthaller 12 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 12 years ago by wthaller

Logged In: YES 

A simple test case is attached.
ghc --make Main.hs works as expected.

ghc -c Foo.hs ; ghc -c Main.hs
yields the following error:

    Exception when trying to run compile-time code:
      typecheck/TcSplice.lhs:(577,4)-(587,87): Non-exhaustive patterns in 

      Code: testReify 'Foo

Changed 12 years ago by wthaller

Attachment: added

comment:2 Changed 12 years ago by wthaller

Logged In: YES 

In fact, it happens whenever no constructors are exported for the data 

comment:3 Changed 12 years ago by nobody

Logged In: NO 

Thanks. Now fixed.


comment:4 Changed 12 years ago by simonpj

Status: assignedclosed
Note: See TracTickets for help on using tickets.