set! weirdness

From: Matthew Liggett <>
Date: Mon, 26 Sep 94 16:22:15 EST

I have an alist which is built like so:

(define al '((varname . value) (varname . value)))

However if I try to do this:

(let ([head (car al)]
      [tail (cdr al)])
   (set! (car head) (cdr head)))

...then STk complains that the 1st argument to set! "(car head)" is not
a symbol.

Of course (symbol? (car head)) returns #t

Any ideas? Is there an easier way to do this?

       "matt liggett" | [v2.1] GCM/CS/P d-- H++>+++ s--: !g p1 au---(*)
   <> | a21 w++ v- C+++ UUALSOX?++++$ P++ L++ 3 E++
'75 Suzuki GT250 '59 Mini | N+++ K- W--- M- V-- po--- Y+ t+ !5 j+ R G' tv-
    ^^4SALE^^ '78 Civic | b+ !D B- e+ u** h- f- r++ n+(----) y++(*)
Received on Mon Sep 26 1994 - 22:15:53 CET

This archive was generated by hypermail 2.3.0 : Mon Jul 21 2014 - 19:38:59 CEST