# HG changeset patch # User Richard M. Stallman # Date 1005709797 0 # Node ID aaa6f44a1b96c29fd64a9fa919722ee33ce03837 # Parent 787bfba12bec0d777d2f9395f420f588f520a151 (ada-fill-comment-prefix): Doc fix. diff -r 787bfba12bec -r aaa6f44a1b96 lisp/progmodes/ada-mode.el --- a/lisp/progmodes/ada-mode.el Wed Nov 14 02:49:26 2001 +0000 +++ b/lisp/progmodes/ada-mode.el Wed Nov 14 03:49:57 2001 +0000 @@ -7,7 +7,7 @@ ;; Markus Heritsch ;; Emmanuel Briot ;; Maintainer: Emmanuel Briot -;; Ada Core Technologies's version: $Revision: 1.43 $ +;; Ada Core Technologies's version: $Revision: 1.44 $ ;; Keywords: languages ada ;; This file is part of GNU Emacs. @@ -283,8 +283,8 @@ (defcustom ada-fill-comment-prefix "-- " "*Text inserted in the first columns when filling a comment paragraph. -Note: if you modify this variable, you will have to restart the `ada-mode' to -reread this variable." +Note: if you modify this variable, you will have to invoke `ada-mode' +again to take account of the new value." :type 'string :group 'ada) (defcustom ada-fill-comment-postfix " --" @@ -4149,16 +4149,13 @@ (goto-char opos) ;; Find beginning of paragraph - (back-to-indentation) - (while (and (not (bobp)) (looking-at "--[ \t]*[^ \t\n]")) - (forward-line -1) - (back-to-indentation)) - - ;; We want one line to above the first one, unless we are at the beginning - ;; of the buffer - (unless (bobp) + (beginning-of-line) + (while (and (not (bobp)) (looking-at "[ \t]*--[ \t]*[^ \t\n]")) + (forward-line -1)) + ;; If we found a paragraph-separating line, + ;; don't actually include it in the paragraph. + (unless (looking-at "[ \t]*--[ \t]*[^ \t\n]") (forward-line 1)) - (beginning-of-line) (setq from (point-marker)) ;; Calculate the indentation we will need for the paragraph