[plt-scheme] append!?

From: Matthias Felleisen (matthias at ccs.neu.edu)
Date: Sat Oct 20 13:18:41 EDT 2007

(append! L1 L2) mutates the first cdr field in L1 that contains NULL  
so that it points to L2.
It then returns L1. If L1 is NULL, it returns L2.

You may wish to think of the overall effect of appending L2 at the  
end of L1, but note that
append! is an imperative procedure and affects all pointers to L1

-- Matthias

On Oct 20, 2007, at 1:10 PM, Majorinc, Kazimir wrote:

> (append! x y) results in concatenation of the values of x and y.
> But, is it guaranteed that result is stored in x? I've read something
> like that in Help Desk, but I'm still not completely without doubt.  
> Do I need to write (set! x (append! x y)) or (append! x y) is  
> always enough?
> Thank you,
> Kazimir Majorinc
> _________________________________________________
>  For list-related administrative tasks:
>  http://list.cs.brown.edu/mailman/listinfo/plt-scheme

Posted on the users mailing list.