mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
New emacs-lisp-byte-code-mode; misc minor changes.
* lisp/emacs-lisp/lisp-mode.el (emacs-list-byte-code-comment-re): New var. (emacs-lisp-byte-code-comment) (emacs-lisp-byte-code-syntax-propertize, emacs-lisp-byte-code-mode): New functions. (eval-sexp-add-defvars): Don't skip defvars in column >0. (eval-defun-2): Remove bogus interactive spec. (lisp-indent-line): Remove redundant whole-exp code, now done in indent-according-to-mode. (save-match-data): Remove redundant indent data. * lisp/emacs-lisp/benchmark.el (benchmark-run, benchmark-run-compiled): Use `declare'. * lisp/gnus/qp.el (quoted-printable-decode-region): Inline+CSE+strength-reduction.
This commit is contained in:
parent
b8b0239fd0
commit
9b851e2550
7 changed files with 101 additions and 31 deletions
|
|
@ -1463,8 +1463,15 @@ Valid clauses are:
|
|||
cl--loop-accum-var))))
|
||||
|
||||
(defun cl--loop-build-ands (clauses)
|
||||
"Return various representations of (and . CLAUSES).
|
||||
CLAUSES is a list of Elisp expressions, where clauses of the form
|
||||
\(progn E1 E2 E3 .. t) are the focus of particular optimizations.
|
||||
The return value has shape (COND BODY COMBO)
|
||||
such that COMBO is equivalent to (and . CLAUSES)."
|
||||
(let ((ands nil)
|
||||
(body nil))
|
||||
;; Look through `clauses', trying to optimize (progn ,@A t) (progn ,@B) ,@C
|
||||
;; into (progn ,@A ,@B) ,@C.
|
||||
(while clauses
|
||||
(if (and (eq (car-safe (car clauses)) 'progn)
|
||||
(eq (car (last (car clauses))) t))
|
||||
|
|
@ -1475,6 +1482,7 @@ Valid clauses are:
|
|||
(cl-cdadr clauses)
|
||||
(list (cadr clauses))))
|
||||
(cddr clauses)))
|
||||
;; A final (progn ,@A t) is moved outside of the `and'.
|
||||
(setq body (cdr (butlast (pop clauses)))))
|
||||
(push (pop clauses) ands)))
|
||||
(setq ands (or (nreverse ands) (list t)))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue