[Haskell-beginners] State as function?

Karl Voelker karl at karlv.net
Sun Apr 6 17:50:02 UTC 2014

On Sun, Apr 6, 2014, at 10:39 AM, Karl Voelker wrote:
> data StringIndex = S1 | S2 | S3 | S4 | S5 | S6 deriving (Eq, Ord, Enum,
> Bounded, Read, Show)

I should have included the Ix class in the deriving list, so you can use
it as an Array index.


More information about the Beginners mailing list