changeset 48935:6047d93c991e

(add-to-invisibility-spec): If it was t, start it out at (t).
author Richard M. Stallman <rms@gnu.org>
date Sun, 22 Dec 2002 22:05:52 +0000
parents 48b3aae63381
children 34c0bb0d7b38
files lisp/subr.el
diffstat 1 files changed, 4 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/subr.el	Sun Dec 22 22:05:16 2002 +0000
+++ b/lisp/subr.el	Sun Dec 22 22:05:52 2002 +0000
@@ -1881,12 +1881,10 @@
   "Add elements to `buffer-invisibility-spec'.
 See documentation for `buffer-invisibility-spec' for the kind of elements
 that can be added."
-  (cond
-   ((or (null buffer-invisibility-spec) (eq buffer-invisibility-spec t))
-	(setq buffer-invisibility-spec (list arg)))
-   (t
-    (setq buffer-invisibility-spec
-	  (cons arg buffer-invisibility-spec)))))
+  (if (eq buffer-invisibility-spec t)
+      (setq buffer-invisibility-spec (list t)))
+  (setq buffer-invisibility-spec
+	(cons arg buffer-invisibility-spec)))
 
 (defun remove-from-invisibility-spec (arg)
   "Remove elements from `buffer-invisibility-spec'."