> I would accept map(foo!, L) with a destructive function foo! to modify L
> in-place, but + isn't such a function.
>
> I think that is not a problem of the representation of AssociationList,
> but rather a problem with the implementation of map.

Your expression is a little strange -- because 'map' is usually defined as:
    map(f, l) == map!(f, copy l)

> Aside from your problem, since we have Rep := Reference List Pair, maybe
> it makes sense to add
>
>   copy x == ref copy deref x

I was talking about adding that definition into AssociationListAggregate,
but yes, a more efficient version should be added to AssociationList.

> In general, it is only a copy of the toplevel structure,
> i.e., a copy of the list structure of association list.

Yes, that's the convention in Lisp, and I think that's fine.

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to