Hi Ryan,
> -Original message-
> From: Ryan Newton
> Sent: 29 Sep 2013, 04:21
>
>
>
> *class Partitionable t where*
> * partition :: t -> Maybe (t,t)*
>
>
>
> So what I really want is for the *containers package to please get some
> kind of Partitionable instances! * Johan & others, I
Hi all,
is there any way to perform a destructive update on a plain ADT?
Imagine I have a simple
data Tree a = Nil | Node a (Tree a) (Tree a)
I would like to be able to modify right subtree of an existing tree.
I can do that for example when using IORefs by changing the datatype to
data Tree
> > is there any way to perform a destructive update on a plain ADT?
> > Imagine I have a simple
> > data Tree a = Nil | Node a (Tree a) (Tree a)
> > I would like to be able to modify right subtree of an existing tree.
> >
> > I can do that for example when using IORefs by changing the datatype t
Hi,
> > is there any way to perform a destructive update on a plain ADT?
>
> Hi Milan, perhaps this is a dumb question, but given that you're using a lazy
> functional language: why do you want to do destructive updates at all?
>
> Perhaps you'd be better off using an imperative/object-oriented
s is not proved yet. If interested,
> let's discuss whether or not we should replace the variant with the
> original in Data.Set/Data.Map.
>
> We guess that Milan Straka, a big contributer of the container
> package, has his opinion. We welcome opinions from other people, two.