]> code.delx.au - gnu-emacs/commitdiff
Add declares for viper-deflocalvar and viper-loop.
authorVegard Øye <vegard_oye@hotmail.com>
Sun, 5 Aug 2012 08:51:59 +0000 (16:51 +0800)
committerChong Yidong <cyd@gnu.org>
Sun, 5 Aug 2012 08:51:59 +0000 (16:51 +0800)
* lisp/emulation/viper-init.el (viper-deflocalvar): Add docstring and
indentation declaration.
(viper-loop): Add indentation declaration.

Fixes: debbugs:7025
lisp/ChangeLog
lisp/emulation/viper-init.el

index 623bf4336b67886d4dfcbc09521bd4d443d6b612..0b86350aef82252d510b0ecfc475bf9997c91390 100644 (file)
@@ -1,3 +1,9 @@
+2012-08-05  Vegard Øye  <vegard_oye@hotmail.com>
+
+       * emulation/viper-init.el (viper-deflocalvar): Add docstring and
+       indentation declaration.
+       (viper-loop): Add indentation declaration (Bug#7025).
+
 2012-08-05  Chong Yidong  <cyd@gnu.org>
 
        * help-fns.el (describe-variable): Add hyperlink for
index 9f0826bf515304fb4bcc4a941f8b697ceb79cf74..c482a88de1aa02eca3e8f163631eef329ca73440 100644 (file)
@@ -96,6 +96,10 @@ In all likelihood, you don't need to bother with this setting."
 ;;; Macros
 
 (defmacro viper-deflocalvar (var default-value &optional documentation)
+  "Define VAR as a buffer-local variable.
+DEFAULT-VALUE is the default value, and DOCUMENTATION is the
+docstring.  The variable becomes buffer-local whenever set."
+  (declare (indent defun))
   `(progn
     (defvar ,var ,default-value
       ,(format "%s\n\(buffer local\)" documentation))
@@ -103,6 +107,7 @@ In all likelihood, you don't need to bother with this setting."
 
 ;; (viper-loop COUNT BODY) Execute BODY COUNT times.
 (defmacro viper-loop (count &rest body)
+  (declare (indent defun))
   `(let ((count ,count))
     (while (> count 0)
       ,@body