[Haskell-cafe] Removing mtl from the Haskell Platform

Neil Brown nccb2 at kent.ac.uk
Wed May 13 07:01:08 EDT 2009


Sittampalam, Ganesh wrote:
> We've discussed replacing it with transformers+monads-fd+an mtl
> compatiblity layer on libraries at . Ross and I plan to propose doing this
> for the second release of the platform - it's not fair to disrupt the
> first release at this stage.
>
> transformers+monads-fd is quite a small evolution over mtl - it factors
> out the fundeps into a separate package, tightens up some of the class
> constraints, and makes State = StateT Identity etc rather than a
> separate type. Even this breaks a few packages, but doing anything more
> substantial would be quite disruptive. That's not to say that we
> shouldn't do it, though.

For those of us wishing to target applications to the Haskell platform 
(e.g. our software works on Haskell Platform 2009.2, 2009.8, etc) will 
there be an easy way to determine which Haskell platform is currently 
installed so that we can accommodate any such incompatible changes?  
E.g. if Haskell platform = 2009.2 then use libraries mtl, parsec and 
#define HP_VERSION 200902, if Haskell platform = 2009.8 then use 
libraries transformers+monads-fd, parsec-compatibility, and #define 
HP_VERSION 200908.

Or am I looking at things the wrong way, and we should instead just use 
autoconf-like tests for individual libraries, regardless of the platform 
(if they have mtl, use mtl and #define USE_MTL, otherwise try 
transformers+monads-fd, otherwise error)?

Thanks,

Neil.


More information about the Haskell-Cafe mailing list