Ranges and the Enum class

Aaron Denney wnoise at ofb.net
Sat Mar 18 12:00:40 EST 2006


On 2006-03-18, Aaron Denney <wnoise at ofb.net> wrote:
> class ArithmeticSequence a where
>     stepFrom      :: a -> [a]            -- [n..]
>     stepFromBy    :: a -> a -> [a]       -- [n,n'..]
>     stepFromTo    :: a -> a -> [a]       -- [n..m]
>     stepFromByTo  :: a -> a -> a -> [a]  -- [n,n'..m]

Whoops, it was a big thinko to change "Then" to "By" here.
These should be stepFromThenTo, etc.

-- 
Aaron Denney
-><-



More information about the Haskell-prime mailing list