From d2df7995826a9e12ef3f9076e675cbdd72298014 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sun, 3 Nov 1996 18:23:24 +0000 Subject: (comment-region): With just C-u as arg, delete any number of comment-end delimiters from end of line. --- lisp/simple.el | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'lisp/simple.el') diff --git a/lisp/simple.el b/lisp/simple.el index f2fb11feeb0..bc4bee00c02 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -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))) -- cgit v1.2.1