Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix interpretation of defsetf lambda lists #348

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Nov 28, 2021

  1. fix interpretation of defsetf lambda lists

    * lib/setf.lisp: (defsetf) use CCL::%DESTRUCTURE-LAMBDA-LIST instead
    of CCL::RENAME-LAMBDA-VARS to come up with a suitable setf
    expansion.
    
    https://lists.clozure.com/pipermail/openmcl-devel/2020-September/012217.html
    
    CCL did not expand defsetf lambda lists of the form
    (defsetf get-foo (&key (add1 1) (add2 (+ add1 2)))
      (data)
     `(setq $foo (- ,data ,add1 ,add2)))
    (get-setf-expansion '(get-foo))
    ;; => The value #:ADD1 is not of the expected type NUMBER.
    
    With this patch
    (setf (get-foo) 10) ;; should return 6
    Madhu committed Nov 28, 2021
    Configuration menu
    Copy the full SHA
    e7552a5 View commit details
    Browse the repository at this point in the history