diff options
| author | Stefan Monnier | 2022-08-23 10:15:48 -0400 |
|---|---|---|
| committer | Stefan Monnier | 2022-08-23 10:16:05 -0400 |
| commit | 3b72b47cbd3e1a4b575d5ecc886e506d22a50a0c (patch) | |
| tree | 63863377c177088afeb6cf373208418a201d8bea | |
| parent | 1a4a12a2a8dbc45bf64fbbd6e19385424d06437d (diff) | |
| download | emacs-3b72b47cbd3e1a4b575d5ecc886e506d22a50a0c.tar.gz emacs-3b72b47cbd3e1a4b575d5ecc886e506d22a50a0c.zip | |
* lisp/progmodes/elisp-mode.el (elisp--local-variables-1): Fix bug#50034
Don't burp if the arg list of a function is not actually a list.
| -rw-r--r-- | lisp/progmodes/elisp-mode.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/progmodes/elisp-mode.el b/lisp/progmodes/elisp-mode.el index 4617a01947c..9dc67010aa7 100644 --- a/lisp/progmodes/elisp-mode.el +++ b/lisp/progmodes/elisp-mode.el | |||
| @@ -383,7 +383,9 @@ be used instead. | |||
| 383 | (setq sexp nil)) | 383 | (setq sexp nil)) |
| 384 | (`(lambda ,args . ,body) | 384 | (`(lambda ,args . ,body) |
| 385 | (elisp--local-variables-1 | 385 | (elisp--local-variables-1 |
| 386 | (append (remq '&optional (remq '&rest args)) vars) | 386 | (let ((args (if (listp args) args))) |
| 387 | ;; FIXME: Exit the loop if witness is in args. | ||
| 388 | (append (remq '&optional (remq '&rest args)) vars)) | ||
| 387 | (car (last body)))) | 389 | (car (last body)))) |
| 388 | (`(condition-case ,_ ,e) (elisp--local-variables-1 vars e)) | 390 | (`(condition-case ,_ ,e) (elisp--local-variables-1 vars e)) |
| 389 | (`(condition-case ,v ,_ . ,catches) | 391 | (`(condition-case ,v ,_ . ,catches) |