# HG changeset patch # User Thien-Thi Nguyen # Date 1126656985 0 # Node ID 4dd9bb8826e88bc9bd5f6b46bfac9bbe723225ee # Parent e441782b5360b213f995c86f4b34a2c92132fd0d Comment munging; nfc. diff -r e441782b5360 -r 4dd9bb8826e8 lisp/progmodes/hideshow.el --- a/lisp/progmodes/hideshow.el Tue Sep 13 20:30:44 2005 +0000 +++ b/lisp/progmodes/hideshow.el Wed Sep 14 00:16:25 2005 +0000 @@ -1,12 +1,12 @@ ;;; hideshow.el --- minor mode cmds to selectively display code/comment blocks ;; Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 -;; 2004, 2005 Free Software Foundation +;; 2004, 2005 Free Software Foundation, Inc. ;; Author: Thien-Thi Nguyen ;; Dan Nicolaescu ;; Keywords: C C++ java lisp tools editing comments blocks hiding outlines -;; Maintainer-Version: 5.58.2.4 +;; Maintainer-Version: ;; Time-of-Day-Author-Most-Likely-to-be-Recalcitrant: early morning ;; This file is part of GNU Emacs. @@ -208,11 +208,11 @@ ;; Thanks go to the following people for valuable ideas, code and ;; bug reports. ;; -;; Dean Andrews, Alf-Ivar Holm, Holger Bauer, Christoph Conrad, Dave -;; Love, Dirk Herrmann, Gael Marziou, Jan Djarv, Guillaume Leray, -;; Moody Ahmad, Preston F. Crow, Lars Lindberg, Reto Zimmermann, -;; Keith Sheffield, Chew Meng Kuan, Tony Lam, Pete Ware, François -;; Pinard, Stefan Monnier, Joseph Eydelnant, Michael Ernst +;; Dean Andrews, Alf-Ivar Holm, Holger Bauer, Christoph Conrad, Dave Love, +;; Dirk Herrmann, Gael Marziou, Jan Djarv, Guillaume Leray, Moody Ahmad, +;; Preston F. Crow, Lars Lindberg, Reto Zimmermann, Keith Sheffield, +;; Chew Meng Kuan, Tony Lam, Pete Ware, François Pinard, Stefan Monnier, +;; Joseph Eydelnant, Michael Ernst, Peter Heslin ;; ;; Special thanks go to Dan Nicolaescu, who reimplemented hideshow using ;; overlays (rather than selective display), added isearch magic, folded @@ -587,7 +587,8 @@ (while (and (< (point) q) (> (point) p) (not (looking-at hs-c-start-regexp))) - (setq p (point)) ;; use this to avoid an infinite cycle + ;; avoid an infinite cycle + (setq p (point)) (forward-comment 1) (skip-chars-forward " \t\n\f")) (when (or (not (looking-at hs-c-start-regexp)) @@ -746,7 +747,7 @@ (funcall hs-hide-all-non-comment-function) (hs-hide-block-at-point t))) ;; found a comment, probably - (let ((c-reg (hs-inside-comment-p))) ; blech! + (let ((c-reg (hs-inside-comment-p))) (when (and c-reg (car c-reg)) (if (> (count-lines (car c-reg) (nth 1 c-reg)) 1) (hs-hide-block-at-point t c-reg) @@ -812,7 +813,8 @@ (setq p (car c-reg) q (cadr c-reg)))) ((and (hs-find-block-beginning) - (looking-at hs-block-start-regexp)) ; fresh match-data, ugh + ;; ugh, fresh match-data + (looking-at hs-block-start-regexp)) (setq p (point) q (progn (hs-forward-sexp (hs-match-data t) 1) (point))))) (when (and p q)