356 |
"Find a comment start between point and LIMIT. |
"Find a comment start between point and LIMIT. |
357 |
Moves point to inside the comment and returns the position of the |
Moves point to inside the comment and returns the position of the |
358 |
comment-starter. If no comment is found, moves point to LIMIT |
comment-starter. If no comment is found, moves point to LIMIT |
359 |
and raises an error or returns nil of NOERROR is non-nil." |
and raises an error or returns nil if NOERROR is non-nil." |
360 |
(if (not comment-use-syntax) |
(if (not comment-use-syntax) |
361 |
(if (re-search-forward comment-start-skip limit noerror) |
(if (re-search-forward comment-start-skip limit noerror) |
362 |
(or (match-end 1) (match-beginning 0)) |
(or (match-end 1) (match-beginning 0)) |
392 |
"Find a comment start between LIMIT and point. |
"Find a comment start between LIMIT and point. |
393 |
Moves point to inside the comment and returns the position of the |
Moves point to inside the comment and returns the position of the |
394 |
comment-starter. If no comment is found, moves point to LIMIT |
comment-starter. If no comment is found, moves point to LIMIT |
395 |
and raises an error or returns nil of NOERROR is non-nil." |
and raises an error or returns nil if NOERROR is non-nil." |
396 |
;; FIXME: If a comment-start appears inside a comment, we may erroneously |
;; FIXME: If a comment-start appears inside a comment, we may erroneously |
397 |
;; stop there. This can be rather bad in general, but since |
;; stop there. This can be rather bad in general, but since |
398 |
;; comment-search-backward is only used to find the comment-column (in |
;; comment-search-backward is only used to find the comment-column (in |
955 |
(defun comment-region (beg end &optional arg) |
(defun comment-region (beg end &optional arg) |
956 |
"Comment or uncomment each line in the region. |
"Comment or uncomment each line in the region. |
957 |
With just \\[universal-argument] prefix arg, uncomment each line in region BEG .. END. |
With just \\[universal-argument] prefix arg, uncomment each line in region BEG .. END. |
958 |
Numeric prefix arg ARG means use ARG comment characters. |
Numeric prefix ARG means use ARG comment characters. |
959 |
If ARG is negative, delete that many comment characters instead. |
If ARG is negative, delete that many comment characters instead. |
960 |
By default, comments start at the left margin, are terminated on each line, |
By default, comments start at the left margin, are terminated on each line, |
961 |
even for syntax in which newline does not end the comment and blank lines |
even for syntax in which newline does not end the comment and blank lines |