Type families: module export of instance data constructor
Wolfgang Jeltsch
g9ks157k at acme.softbase.org
Sun Dec 21 20:23:30 EST 2008
Am Montag, 15. Dezember 2008 02:17 schrieb Ben Horsfall:
> I have a type family
>
> class Lang term where
> data Token term :: *
>
> with
>
> instance Lang Term where
> newtype Token Term = T String
>
> I can't work out how to export the type constructor T from the module,
> unless I make no explict exports from the module at all.
>
>
> Ben
Hello Ben,
try
Lang (type Token)
in the export list.
Best wishes,
Wolfgang
More information about the Glasgow-haskell-users
mailing list