[Haskell-cafe] Re: Data instance for a GADT
Simon Peyton-Jones
simonpj at microsoft.com
Tue May 25 12:35:58 EDT 2010
There have been a couple of emails about Template Haskell support for
· GADTs
· View patterns
· Reifying instances
There’s a ticket for this already http://hackage.haskell.org/trac/ghc/ticket/3497
It’s mainly a library design question, in this case the design of the Template Haskell data types in Language.Haskell.TH.Syntax. It needs some motivated person to propose a design, get a consensus, and write some boilerplate code. Just use the standard libraries process
An issue is the extent to which it’s ok to change the Template Haskell data types (and thereby break people’s code), but that’s something the interested parties can work out together.
If you evolve a consensus design I’m more than happy to make it part of GHC. I just don’t want to drive the consensus building!
Simon
From: haskell-cafe-bounces at haskell.org [mailto:haskell-cafe-bounces at haskell.org] On Behalf Of Ozgur Akgun
Sent: 14 April 2010 10:53
To: Haskell cafe
Subject: [Haskell-cafe] Re: Data instance for a GADT
Seeing this old thread[1], I hope something happened towards enabling this.
Does anybody know the current status about using TH on GADTs?
[1] http://www.haskell.org/pipermail/template-haskell/2006-August/000567.html
On 14 April 2010 10:32, Ozgur Akgun <ozgurakgun at gmail.com<mailto:ozgurakgun at gmail.com>> wrote:
answering to myself: I guess this is related: http://hackage.haskell.org/trac/ghc/ticket/3497
On 14 April 2010 10:13, Ozgur Akgun <ozgurakgun at gmail.com<mailto:ozgurakgun at gmail.com>> wrote:
Cafe,
How can I provide a Data instance for a GADT? I am trying to TH on it, and Uniplate requires Data.
I tried StandaloneDeriving, but it seems not to work.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20100525/7b98fa98/attachment.html
More information about the Haskell-Cafe
mailing list