]> git.eshelyaron.com Git - emacs.git/commitdiff
(comment-region): With just C-u as arg,
authorRichard M. Stallman <rms@gnu.org>
Sun, 3 Nov 1996 18:23:24 +0000 (18:23 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sun, 3 Nov 1996 18:23:24 +0000 (18:23 +0000)
delete any number of comment-end delimiters from end of line.

lisp/simple.el

index f2fb11feeb064ec5b9ddb982191c85ee3fd8f73b..bc4bee00c02aabc82cfae47d94c8a131da911f3a 100644 (file)
@@ -2264,11 +2264,11 @@ not end the comment.  Blank lines do not get comments."
                        ;; This is questionable if comment-end ends in
                        ;; whitespace.  That is pretty brain-damaged,
                        ;; though.
-                       (skip-chars-backward " \t")
-                       (if (and (>= (- (point) (point-min)) (length ce))
-                                (save-excursion
-                                  (backward-char (length ce))
-                                  (looking-at (regexp-quote ce))))
+                       (while (progn (skip-chars-backward " \t")
+                                     (and (>= (- (point) (point-min)) (length ce))
+                                          (save-excursion
+                                            (backward-char (length ce))
+                                            (looking-at (regexp-quote ce)))))
                            (delete-char (- (length ce)))))
                    (let ((count numarg))
                      (while (> 1 (setq count (1+ count)))