aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/textmodes
diff options
context:
space:
mode:
authorCarsten Dominik <[email protected]>2007-10-25 14:24:43 +0000
committerCarsten Dominik <[email protected]>2007-10-25 14:24:43 +0000
commit557f46f04b87f68c2587bc6c8ecc7d7806f7d22f (patch)
tree2aed4e9507c83bd83a249e6d2bb566f50edfdc85 /lisp/textmodes
parent429f0457ea0da2452b56360a06959b5dc7198bd3 (diff)
(org-no-warnings): New macro.
(org-columns-eval): Use `org-no-warnings'.
Diffstat (limited to 'lisp/textmodes')
-rw-r--r--lisp/textmodes/org.el8
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el
index 449e260423..4ba90216d8 100644
--- a/lisp/textmodes/org.el
+++ b/lisp/textmodes/org.el
@@ -15611,14 +15611,15 @@ Where possible, use the standard interface for changing this line."
org-columns-top-level-marker))
key1 nval)))
+(defmacro org-no-warnings (&rest body)
+ (cons (if (fboundp 'with-no-warnings) 'with-no-warnings 'progn) body))
+
(defun org-columns-eval (form)
(let (hidep)
(save-excursion
(beginning-of-line 1)
;; `next-line' is needed here, because it skips invisible line.
- ;; FIXME: RMS says this should be wrapped into `with-no-warnings'
- ;; but I don't know how to do this and keep the code XEmacs compatible.
- (condition-case nil (next-line 1) (error nil))
+ (condition-case nil (org-no-warnings (next-line 1)) (error nil))
(setq hidep (org-on-heading-p 1)))
(eval form)
(and hidep (hide-entry))))
@@ -26486,3 +26487,4 @@ Respect keys that are already there."
;; arch-tag: e77da1a7-acc7-4336-b19e-efa25af3f9fd
;;; org.el ends here
+