fukamachi / assoc-utils

Utilities for manipulating association lists.
25 stars 1 forks source link

delete-from-alistf can't delete first element in alist #3

Closed ailisp closed 6 years ago

ailisp commented 6 years ago
CL-USER> (defparameter *a* '((:a . 1) (:b . 2)))
*A*
CL-USER> (assoc-utils:delete-from-alist *a* :a)
((:B . 2))
CL-USER> *a*
((:A . 1) (:B . 2))
CL-USER> (assoc-utils:delete-from-alistf *a* :a)
((:B . 2))
CL-USER> *a*
((:B . 2))
CL-USER> 

In Mac, SBCL 1.4.6

ailisp commented 6 years ago

Sorry, not a bug, I should use delete-from-alist with setf. Obviously I forget basic concepts of CL modify macros