1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-03 10:31:37 -08:00

* lisp/subr.el (zerop): Move from C. Add compiler-macro.

* lisp/emacs-lisp/byte-opt.el (byte-optimize-zerop): Remove.
* src/data.c (Fzerop): Move to Elisp.
(syms_of_data): Don't defsubr it.
* src/keyboard.c (echo_keystrokes_p): New function.
(read_char, record_menu_key, read_key_sequence): Use it.

Fixes: debbugs:17475
This commit is contained in:
Stefan Monnier 2014-05-27 20:50:44 -04:00
parent 0e4857b7d8
commit 4c539a7b38
6 changed files with 43 additions and 47 deletions

View file

@ -942,15 +942,6 @@
form
(nth 1 form)))
(defun byte-optimize-zerop (form)
(cond ((numberp (nth 1 form))
(eval form))
(byte-compile-delete-errors
(list '= (nth 1 form) 0))
(form)))
(put 'zerop 'byte-optimizer 'byte-optimize-zerop)
(defun byte-optimize-and (form)
;; Simplify if less than 2 args.
;; if there is a literal nil in the args to `and', throw it and following