From d5c31f1ddd83e958d4b944d7aa94302359f8ecf9 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Vegard=20=C3=98ye?= Date: Sun, 5 Aug 2012 16:51:59 +0800 Subject: [PATCH] Add declares for viper-deflocalvar and viper-loop. * lisp/emulation/viper-init.el (viper-deflocalvar): Add docstring and indentation declaration. (viper-loop): Add indentation declaration. Fixes: debbugs:7025 --- lisp/ChangeLog | 6 ++++++ lisp/emulation/viper-init.el | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 623bf4336b..0b86350aef 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2012-08-05 Vegard Øye + + * emulation/viper-init.el (viper-deflocalvar): Add docstring and + indentation declaration. + (viper-loop): Add indentation declaration (Bug#7025). + 2012-08-05 Chong Yidong * help-fns.el (describe-variable): Add hyperlink for diff --git a/lisp/emulation/viper-init.el b/lisp/emulation/viper-init.el index 9f0826bf51..c482a88de1 100644 --- a/lisp/emulation/viper-init.el +++ b/lisp/emulation/viper-init.el @@ -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 -- 2.39.2