* lisp/subr.el (track-mouse): New macro.

* lisp/emacs-lisp/cconv.el (cconv-convert, cconv-analyse-form):
Remove track-mouse case.
* lisp/emacs-lisp/bytecomp.el (byte-compile-track-mouse): Remove.
* src/keyboard.c (track-mouse): Rename to internal--track-mouse.
Make it into a function and change arg to be a function.
This commit is contained in:
Stefan Monnier 2014-09-27 11:52:28 -04:00
parent 548e169622
commit 19e0f0af6d
6 changed files with 22 additions and 24 deletions

View file

@ -462,10 +462,6 @@ places where they originally did not directly appear."
`(,head ,(cconv-convert form env extend)
:fun-body ,(cconv--convert-function () body env form)))
(`(track-mouse . ,body)
`(track-mouse
:fun-body ,(cconv--convert-function () body env form)))
(`(setq . ,forms) ; setq special form
(let ((prognlist ()))
(while forms
@ -701,11 +697,6 @@ and updates the data stored in ENV."
(cconv-analyse-form form env)
(cconv--analyse-function () body env form))
;; FIXME: The lack of bytecode for track-mouse forces us to wrap the body.
;; `track-mouse' really should be made into a macro.
(`(track-mouse . ,body)
(cconv--analyse-function () body env form))
(`(defvar ,var) (push var byte-compile-bound-variables))
(`(,(or `defconst `defvar) ,var ,value . ,_)
(push var byte-compile-bound-variables)