emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bug in CL with destructuring-bind and default arguments


From: Jeremy Maitin-Shepard
Subject: Bug in CL with destructuring-bind and default arguments
Date: Fri, 05 Sep 2008 10:23:35 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

Hello,

I've noticed a bug in CL with destructuring-bind:

This should work:

(destructuring-bind (&optional (a 1)) '() a)

But instead it gives an error:

Debugger entered--Lisp error: (void-variable bind-enquote)
  cl-do-arglist((&optional (a 1)) 'nil)
  #[(args expr &rest body) "ƉƉÇȆÉ
\"ˆÊË\nÌŸD     Ÿ¤¤C#-‡" [bind-lets bind-forms bind-inits bind-defs bind-block 
args nil cl-none cl-do-arglist (&aux) append (progn) let* expr body] 
6]((&optional (a 1)) 'nil a)
  (destructuring-bind (&optional (a 1)) 'nil a)
  eval((destructuring-bind (&optional (a 1)) 'nil a))
  eval-last-sexp-1(nil)
  eval-last-sexp(nil)
  call-interactively(eval-last-sexp nil nil)

Let-binding bind-enquote to nil in the definition of destructuring-bind
seems to fix the problem (as does wrapping such a let-bind around the
call to destructuring-bind), but I don't know if that is the right fix.

My Emacs version is a CVS build: GNU Emacs 23.0.60.1 (x86_64-pc-linux-gnu) of 
2008-07-25
but I suspect this bug has been around for ages.

-- 
Jeremy Maitin-Shepard




reply via email to

[Prev in Thread] Current Thread [Next in Thread]