[Haskell-cafe] Re: AlternativePrelude extension

Taru Karttunen taruti at taruti.net
Sun Jan 17 08:54:01 EST 2010


Excerpts from Roel van Dijk's message of Sun Jan 17 13:50:22 +0200 2010:
> The "extensions" field in a cabal package description is a bit tricky.
> The documentation states "A list of Haskell extensions used by every
> module". This might give the impression that it documents the various
> extensions used in a package. What it actually does is enable those
> extensions for every module.
> 
> Duncan's comments on this ticket are enlightening:
> http://hackage.haskell.org/trac/hackage/ticket/370
> 
> I think the idea of adding a new field "used-extensions" warrants a
> separate ticket.

Why not have Cabal autogenerate that information?

Hackage already displays generated info like "Built on" and thus
it should be doable. i.e.

1) Scan all the source files used for extension pragmas
2) Generate a list of those
3) Include that on Hackage

The functionality needed for this is also needed for validating
the proposed used-extensions field is correct, and thus not harder to
implement.

- Taru Karttunen


More information about the Haskell-Cafe mailing list