From 8bb17f6471522c30630d0571a8b31d09554a17c2 Mon Sep 17 00:00:00 2001 From: Daniel Colascione Date: Sat, 24 May 2014 12:51:52 -0700 Subject: [PATCH] Unbreak the build * lisp/emacs-lisp/nadvice.el (defun): Write in eval-and-compile to avoid breaking the build. --- lisp/ChangeLog | 5 +++++ lisp/emacs-lisp/nadvice.el | 11 ++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b786027f76..a14af45cc7 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-05-24 Daniel Colascione + + * emacs-lisp/nadvice.el (defun): Write in eval-and-compile to avoid + breaking the build. + 2014-05-24 Leo Liu * calc/calc.el (math-bignum): Handle most-negative-fixnum. (Bug#17556) diff --git a/lisp/emacs-lisp/nadvice.el b/lisp/emacs-lisp/nadvice.el index 01027c4314..66a4f8fdea 100644 --- a/lisp/emacs-lisp/nadvice.el +++ b/lisp/emacs-lisp/nadvice.el @@ -232,11 +232,12 @@ different, but `function-equal' will hopefully ignore those differences.") ;; This function acts like the t special value in buffer-local hooks. (lambda (&rest args) (apply (default-value var) args))))) -(defun advice--normalize-place (place) - (cond ((eq 'local (car-safe place)) `(advice--buffer-local ,@(cdr place))) - ((eq 'var (car-safe place)) (nth 1 place)) - ((symbolp place) `(default-value ',place)) - (t place))) +(eval-and-compile + (defun advice--normalize-place (place) + (cond ((eq 'local (car-safe place)) `(advice--buffer-local ,@(cdr place))) + ((eq 'var (car-safe place)) (nth 1 place)) + ((symbolp place) `(default-value ',place)) + (t place)))) ;;;###autoload (defmacro add-function (where place function &optional props) -- 2.20.1