[Haskell-beginners] Identifying general patterns / typeclass instances

Tim Cowlishaw tim at timcowlishaw.co.uk
Mon Aug 8 09:18:23 CEST 2011


On Mon, Aug 8, 2011 at 4:25 AM, yi huang <yi.codeplayer at gmail.com> wrote:
> I'm wondering how you gonna `append' two state ?

Yeah - I've skirted round the details of this by specifying a monoid
restriction on the type of the simulation state, which is a pretty big
assumption (the associativity law is what's likely to be a problem I
think), However, I figured I could start with this restriction and
then try and generalise to the trickier case where the state type is
not a monoid later...

Thanks!

Tim



More information about the Beginners mailing list