]> git.eshelyaron.com Git - emacs.git/commitdiff
comment-beginning: doc-fix and don't choke on unset comment-end-skip when at beginnin...
authorDaniel Pfeiffer <occitan@esperanto.org>
Sun, 3 Oct 2004 15:36:18 +0000 (15:36 +0000)
committerDaniel Pfeiffer <occitan@esperanto.org>
Sun, 3 Oct 2004 15:36:18 +0000 (15:36 +0000)
lisp/ChangeLog
lisp/newcomment.el

index dd26fb647bcc15986f0720594dcb72a81978416b..d80e70510c063584b9e4ad16fcbbf7f5e0def3af 100644 (file)
@@ -1,3 +1,8 @@
+2004-10-03  Daniel Pfeiffer  <occitan@esperanto.org>
+
+       * newcomment.el (comment-beginning): Doc fix and don't choke on
+       unset `comment-end-skip' when at beginning of comment
+
 2004-10-02  Dan Nicolaescu  <dann@ics.uci.edu>
 
        * term.el (term-adjust-current-row-cache): Don't allow the current
@@ -5,9 +10,9 @@
        (term-emulate-terminal): Fix insert mode. Handle tab insertion at
        the end of the line. Fix scroll down. Add comments.
        (term-handle-ansi-escape): Don't exceed terminal width when moving
-       right.  
+       right.
        (term-scroll-region): Move the cursor after setting the scroll
-       region. 
+       region.
 
 2004-10-01  Luc Teirlinck  <teirllm@auburn.edu>
 
index 120777ab704cea80e6fd1929db1386165d77fa5e..5711e7903ad28fb8d3505946e01e9fad28bc8e28 100644 (file)
@@ -423,7 +423,7 @@ and raises an error or returns nil if NOERROR is non-nil."
 (defun comment-beginning ()
   "Find the beginning of the enclosing comment.
 Returns nil if not inside a comment, else moves point and returns
-the same as `comment-search-forward'."
+the same as `comment-search-backward'."
   ;; HACK ATTACK!
   ;; We should really test `in-string-p' but that can be expensive.
   (unless (eq (get-text-property (point) 'face) 'font-lock-string-face)
@@ -435,7 +435,7 @@ the same as `comment-search-forward'."
              (and
               ;; For modes where comment-start and comment-end are the same,
               ;; the search above may have found a `ce' rather than a `cs'.
-              (or (not (looking-at comment-end-skip))
+              (or (if comment-end-skip (not (looking-at comment-end-skip)))
                   ;; Maybe font-lock knows that it's a `cs'?
                   (eq (get-text-property (match-end 0) 'face)
                       'font-lock-comment-face)