[Haskell-cafe] 'data' syntax - a suggestion
jerzy.karczmarczuk at info.unicaen.fr
jerzy.karczmarczuk at info.unicaen.fr
Thu Sep 27 05:33:11 EDT 2007
Thomas Conway writes:
> On 9/27/07, ok <ok at cs.otago.ac.nz> wrote:
>> I have often found myself wishing for a small extension to the syntax of
>> Haskell 'data' declarations. It goes like this:
> ['where' clause to allow locally defined names in type declarations]
>
> Nice.
>
> Quite a few times I've found myself declaring type synonyms for this
> reason, but you end up polluting the global namespace.
>
> +1 vote.
Data with where?
You haven't heard about GADTs?
http://en.wikibooks.org/wiki/Haskell/GADT
http://www.haskell.org/haskellwiki/Generalised_algebraic_datatype
Jerzy Karczmarczuk
More information about the Haskell-Cafe
mailing list