aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLute Kamstra2005-02-15 09:23:22 +0000
committerLute Kamstra2005-02-15 09:23:22 +0000
commit43817a7520247657839eed5705ab22192c4c94b3 (patch)
tree58478e67e69a81d4c262d8024f8d08aa59060d9c
parente7212bb36eb43c99a23b7698566c3d94357a153d (diff)
downloademacs-43817a7520247657839eed5705ab22192c4c94b3.tar.gz
emacs-43817a7520247657839eed5705ab22192c4c94b3.zip
(lisp-mode-variables): Add ;;;###autoload to `outline-regexp'.
Suggested by Stefan Monnier <monnier@iro.umontreal.ca> (lisp-outline-level): Improve efficiency. Suggested by David Kastrup <dak@gnu.org>.
-rw-r--r--lisp/ChangeLog8
-rw-r--r--lisp/emacs-lisp/lisp-mode.el11
2 files changed, 13 insertions, 6 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 89bfdbf94a1..3eabad53563 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,11 @@
12005-02-15 Lute Kamstra <lute@gnu.org>
2
3 * emacs-lisp/lisp-mode.el (lisp-mode-variables): Add
4 ;;;###autoload to `outline-regexp'. Suggested by Stefan Monnier
5 <monnier@iro.umontreal.ca>
6 (lisp-outline-level): Improve efficiency. Suggested by David
7 Kastrup <dak@gnu.org>.
8
12005-02-15 Nick Roberts <nickrob@snap.net.nz> 92005-02-15 Nick Roberts <nickrob@snap.net.nz>
2 10
3 * progmodes/gdb-ui.el (gdb-find-file-unhook): New variable. 11 * progmodes/gdb-ui.el (gdb-find-file-unhook): New variable.
diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el
index 6b5c0b1c0f1..1a7da113c12 100644
--- a/lisp/emacs-lisp/lisp-mode.el
+++ b/lisp/emacs-lisp/lisp-mode.el
@@ -182,7 +182,7 @@
182 (make-local-variable 'parse-sexp-ignore-comments) 182 (make-local-variable 'parse-sexp-ignore-comments)
183 (setq parse-sexp-ignore-comments t) 183 (setq parse-sexp-ignore-comments t)
184 (make-local-variable 'outline-regexp) 184 (make-local-variable 'outline-regexp)
185 (setq outline-regexp ";;;;* [^ \t\n]\\|(") 185 (setq outline-regexp ";;;\\(;* [^ \t\n]\\|###autoload\\)\\|(")
186 (make-local-variable 'outline-level) 186 (make-local-variable 'outline-level)
187 (setq outline-level 'lisp-outline-level) 187 (setq outline-level 'lisp-outline-level)
188 (make-local-variable 'comment-start) 188 (make-local-variable 'comment-start)
@@ -212,11 +212,10 @@
212 212
213(defun lisp-outline-level () 213(defun lisp-outline-level ()
214 "Lisp mode `outline-level' function." 214 "Lisp mode `outline-level' function."
215 (if (looking-at "(\\|;;;###autoload") 215 (let ((len (- (match-end 0) (match-beginning 0))))
216 1000 216 (if (looking-at "(\\|;;;###autoload")
217 (looking-at outline-regexp) 217 1000
218 (- (match-end 0) (match-beginning 0)))) 218 len)))
219
220 219
221(defvar lisp-mode-shared-map 220(defvar lisp-mode-shared-map
222 (let ((map (make-sparse-keymap))) 221 (let ((map (make-sparse-keymap)))