Commit 01e4a4fa authored by Stefan Monnier's avatar Stefan Monnier
Browse files

(byte-compile-make-variable-buffer-local)

(byte-compile-form-make-variable-buffer-local): New functions to warn about
misuses of make-variable-buffer-local where make-local-variable was meant.
parent d0278ce8
2005-07-29 Stefan Monnier <monnier@iro.umontreal.ca>
* emacs-lisp/bytecomp.el (byte-compile-make-variable-buffer-local)
(byte-compile-form-make-variable-buffer-local): New functions to warn
about misuses of make-variable-buffer-local where make-local-variable
was meant.
2005-07-29 Juanma Barranquero <lekktu@gmail.com>
 
* bs.el (bs-attributes-list): Doc fix.
......@@ -21,8 +28,8 @@
 
2005-07-29 Kenichi Handa <handa@m17n.org>
 
* international/mule-cmds.el (select-message-coding-system): Be
sure to use LF for end-of-line. If no coding system is decided,
* international/mule-cmds.el (select-message-coding-system):
Be sure to use LF for end-of-line. If no coding system is decided,
return iso-8859-1-unix.
 
2005-07-28 Stefan Monnier <monnier@iro.umontreal.ca>
......@@ -89,17 +96,15 @@
 
* term/README: Describe the terminal-init-* functionality.
 
* startup.el (command-line): After loading the terminal
initialization file call the corresponding terminal initialization
function.
* startup.el (command-line): After loading the terminal initialization
file call the corresponding terminal initialization function.
 
2005-07-27 Kenichi Handa <handa@m17n.org>
 
* ps-bdf.el (bdf-read-font-info): Ignore glyphs whose ENCODING is
negative.
 
* ps-mule.el (ps-mule-bitmap-prologue): Fix arguments to
setcharwidth.
* ps-mule.el (ps-mule-bitmap-prologue): Fix arguments to setcharwidth.
(ps-mule-composition-prologue): Fix for the case that
RelativeCompose is false.
 
......
......@@ -3790,6 +3790,19 @@ that suppresses all warnings during execution of BODY."
(defun byte-compile-no-warnings (form)
(let (byte-compile-warnings)
(byte-compile-form (cons 'progn (cdr form)))))
;; Warn about misuses of make-variable-buffer-local.
(byte-defop-compiler-1 make-variable-buffer-local byte-compile-make-variable-buffer-local)
(defun byte-compile-make-variable-buffer-local (form)
(if (eq (car-safe (car-safe (cdr-safe form))) 'quote)
(byte-compile-warn
"`make-variable-buffer-local' should be called at toplevel"))
(byte-compile-normal-call form))
(put 'make-variable-buffer-local
'byte-hunk-handler 'byte-compile-form-make-variable-buffer-local)
(defun byte-compile-form-make-variable-buffer-local (form)
(byte-compile-keep-pending form 'byte-compile-normal-call))
;;; tags
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment