emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r112395: * lisp/progmodes/octave.el (


From: Stefan Monnier
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r112395: * lisp/progmodes/octave.el (octave-smie-forward-token): Properly skip
Date: Fri, 26 Apr 2013 10:34:26 -0400
User-agent: Bazaar (2.5.0)

------------------------------------------------------------
revno: 112395
fixes bug: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=14218
committer: Stefan Monnier <address@hidden>
branch nick: trunk
timestamp: Fri 2013-04-26 10:34:26 -0400
message:
  * lisp/progmodes/octave.el (octave-smie-forward-token): Properly skip
  \n and comment, even if it's not an implicit ;.
modified:
  lisp/ChangeLog
  lisp/progmodes/octave.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2013-04-26 07:34:54 +0000
+++ b/lisp/ChangeLog    2013-04-26 14:34:26 +0000
@@ -1,3 +1,8 @@
+2013-04-26  Stefan Monnier  <address@hidden>
+
+       * progmodes/octave.el (octave-smie-forward-token): Properly skip
+       \n and comment, even if it's not an implicit ; (bug#14218).
+
 2013-04-26  Glenn Morris  <address@hidden>
 
        * subr.el (read-number): Once more use `read' rather than
@@ -20,7 +25,7 @@
 
        * progmodes/octave.el (octave-submit-bug-report): Obsolete.
        (octave-mode, inferior-octave-mode): Use setq-local.
-       (octave-not-in-string-or-comment-p): Renamed to
+       (octave-not-in-string-or-comment-p): Rename to
        octave-in-string-or-comment-p.
        (octave-in-comment-p, octave-in-string-p)
        (octave-in-string-or-comment-p): Replace defsubst with defun.
@@ -36,8 +41,8 @@
 
 2013-04-25  Leo Liu  <address@hidden>
 
-       * progmodes/octave.el (octave-completion-at-point-function): Make
-       use of inferior octave process.
+       * progmodes/octave.el (octave-completion-at-point-function):
+       Make use of inferior octave process.
        (octave-initialize-completions): Remove.
        (inferior-octave-completion-table): New function.
        (inferior-octave-completion-at-point): Use it.

=== modified file 'lisp/progmodes/octave.el'
--- a/lisp/progmodes/octave.el  2013-04-26 04:16:37 +0000
+++ b/lisp/progmodes/octave.el  2013-04-26 14:34:26 +0000
@@ -461,11 +461,12 @@
     (forward-comment 1))
   (cond
    ((and (looking-at "$\\|[%#]")
-         (not (smie-rule-bolp))
-         ;; Ignore it if it's within parentheses.
-         (prog1 (let ((ppss (syntax-ppss)))
-                  (not (and (nth 1 ppss)
-                            (eq ?\( (char-after (nth 1 ppss))))))
+         ;; Ignore it if it's within parentheses or if the newline does not end
+         ;; some preceding text.
+         (prog1 (and (not (smie-rule-bolp))
+                    (let ((ppss (syntax-ppss)))
+                      (not (and (nth 1 ppss)
+                                (eq ?\( (char-after (nth 1 ppss)))))))
            (forward-comment (point-max))))
     ;; Why bother distinguishing \n and ;?
     ";") ;;"\n"


reply via email to

[Prev in Thread] Current Thread [Next in Thread]