+2005-02-15 Lute Kamstra <lute@gnu.org>
+
+ * emacs-lisp/lisp-mode.el (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>.
+
2005-02-15 Nick Roberts <nickrob@snap.net.nz>
* progmodes/gdb-ui.el (gdb-find-file-unhook): New variable.
(make-local-variable 'parse-sexp-ignore-comments)
(setq parse-sexp-ignore-comments t)
(make-local-variable 'outline-regexp)
- (setq outline-regexp ";;;;* [^ \t\n]\\|(")
+ (setq outline-regexp ";;;\\(;* [^ \t\n]\\|###autoload\\)\\|(")
(make-local-variable 'outline-level)
(setq outline-level 'lisp-outline-level)
(make-local-variable 'comment-start)
(defun lisp-outline-level ()
"Lisp mode `outline-level' function."
- (if (looking-at "(\\|;;;###autoload")
- 1000
- (looking-at outline-regexp)
- (- (match-end 0) (match-beginning 0))))
-
+ (let ((len (- (match-end 0) (match-beginning 0))))
+ (if (looking-at "(\\|;;;###autoload")
+ 1000
+ len)))
(defvar lisp-mode-shared-map
(let ((map (make-sparse-keymap)))