
On Fri, May 31, 2013 at 11:06 AM, Adrian May wrote: Well I figured out that I should be using the State monad, but it seems
not to be behaving like most of the tutorials on the web. Did the syntax
change? .... mtl-2.x changed all the base monads (State, Reader, Writer, etc.) from
standalone to being transformers atop an Identity monad; this cleans up the
implementation considerably (since we don't have almost exactly the same
code for both the standalone and transformer versions, but means that all
uses of the standalone constructors must be replaced with functions that
build the appropriate transformer. (e.g. State becomes state, unless you
want to spell it out as StateT Identity.)
--
brandon s allbery kf8nh sine nomine associates
allbery.b@gmail.com ballbery@sinenomine.net
unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net