On Wednesday 29 May 2002 02:58, Hal Daume III wrote:
Is there any particular reason FiniteMap (and hence Set) aren't instances
of Ord? I realize it's weird to define a map to be ordered, but even if
the Ord definition were in some sense nonsensical, being able to have,
for instance, Sets of
(Re: Eray's code using FiniteMaps/Sets)
Comments welcome,
I'd suggest
show s = mkSet ++ show (setToList s)
show fm = listToFM ++ show (fmToList fm)
That way you can easily paste the output of a program
into your code back again, and you can easily tell
the type of the `showed'