mercurial.el: move defmacro of hg-do-across-repo before use
authorNIIMI Satoshi <sa2c@sa2c.net>
Sat, 05 May 2007 15:50:40 +0900
changeset 4412 189a8ca52bfc
parent 4411 681b681f7f09
child 4413 b008deae9910
mercurial.el: move defmacro of hg-do-across-repo before use Macros must be defined before use to be byte-compiled properly.
contrib/mercurial.el
--- a/contrib/mercurial.el	Mon May 07 08:42:48 2007 -0700
+++ b/contrib/mercurial.el	Sat May 05 15:50:40 2007 +0900
@@ -317,6 +317,18 @@
 	       (car res))
       (cdr res))))
 
+(defmacro hg-do-across-repo (path &rest body)
+  (let ((root-name (gensym "root-"))
+	(buf-name (gensym "buf-")))
+    `(let ((,root-name (hg-root ,path)))
+       (save-excursion
+	 (dolist (,buf-name (buffer-list))
+	   (set-buffer ,buf-name)
+	   (when (and hg-status (equal (hg-root buffer-file-name) ,root-name))
+	     ,@body))))))
+
+(put 'hg-do-across-repo 'lisp-indent-function 1)
+
 (defun hg-sync-buffers (path)
   "Sync buffers visiting PATH with their on-disk copies.
 If PATH is not being visited, but is under the repository root, sync
@@ -539,18 +551,6 @@
 	    (set-buffer buf)
 	    (hg-mode-line-internal status parents)))))))
   
-(defmacro hg-do-across-repo (path &rest body)
-  (let ((root-name (gensym "root-"))
-	(buf-name (gensym "buf-")))
-    `(let ((,root-name (hg-root ,path)))
-       (save-excursion
-	 (dolist (,buf-name (buffer-list))
-	   (set-buffer ,buf-name)
-	   (when (and hg-status (equal (hg-root buffer-file-name) ,root-name))
-	     ,@body))))))
-
-(put 'hg-do-across-repo 'lisp-indent-function 1)
-
 
 ;;; View mode bits.