diff options
| author | Leo Liu | 2013-06-21 14:45:37 +0800 |
|---|---|---|
| committer | Leo Liu | 2013-06-21 14:45:37 +0800 |
| commit | 62efb35e42807972b8599e52c42e2c7302e25aa8 (patch) | |
| tree | 06dce5254c6cd0362740a1ed672804cfd15e198e | |
| parent | 21e3f963e7472f5b9721ff9dc5b683efc6b3e9b8 (diff) | |
| download | emacs-62efb35e42807972b8599e52c42e2c7302e25aa8.tar.gz emacs-62efb35e42807972b8599e52c42e2c7302e25aa8.zip | |
* progmodes/octave.el (octave-mode): Backward compatibility fix.
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/progmodes/octave.el | 11 |
2 files changed, 11 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1b1714711ca..7c6a59c75f7 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2013-06-21 Leo Liu <sdl.web@gmail.com> | ||
| 2 | |||
| 3 | * progmodes/octave.el (octave-mode): Backward compatibility fix. | ||
| 4 | |||
| 1 | 2013-06-21 Glenn Morris <rgm@gnu.org> | 5 | 2013-06-21 Glenn Morris <rgm@gnu.org> |
| 2 | 6 | ||
| 3 | * font-lock.el (lisp-font-lock-keywords-2): Add with-eval-after-load. | 7 | * font-lock.el (lisp-font-lock-keywords-2): Add with-eval-after-load. |
diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el index 4e5a3058d4e..de1c26a7fa7 100644 --- a/lisp/progmodes/octave.el +++ b/lisp/progmodes/octave.el | |||
| @@ -554,8 +554,13 @@ definitions can also be stored in files and used in batch mode." | |||
| 554 | 554 | ||
| 555 | (setq-local fill-nobreak-predicate | 555 | (setq-local fill-nobreak-predicate |
| 556 | (lambda () (eq (octave-in-string-p) ?'))) | 556 | (lambda () (eq (octave-in-string-p) ?'))) |
| 557 | (add-function :around (local 'comment-line-break-function) | 557 | (with-no-warnings |
| 558 | #'octave--indent-new-comment-line) | 558 | (if (fboundp 'add-function) ; new in 24.4 |
| 559 | (add-function :around (local 'comment-line-break-function) | ||
| 560 | #'octave--indent-new-comment-line) | ||
| 561 | (setq-local comment-line-break-function | ||
| 562 | (apply-partially #'octave--indent-new-comment-line | ||
| 563 | #'comment-indent-new-line)))) | ||
| 559 | 564 | ||
| 560 | (setq font-lock-defaults '(octave-font-lock-keywords)) | 565 | (setq font-lock-defaults '(octave-font-lock-keywords)) |
| 561 | 566 | ||
| @@ -1151,8 +1156,6 @@ q: Don't fix\n" func file)) | |||
| 1151 | ;;; Indentation | 1156 | ;;; Indentation |
| 1152 | 1157 | ||
| 1153 | (defun octave-indent-new-comment-line (&optional soft) | 1158 | (defun octave-indent-new-comment-line (&optional soft) |
| 1154 | ;; FIXME: C-M-j should probably be bound globally to a function like | ||
| 1155 | ;; this one. | ||
| 1156 | "Break Octave line at point, continuing comment if within one. | 1159 | "Break Octave line at point, continuing comment if within one. |
| 1157 | Insert `octave-continuation-string' before breaking the line | 1160 | Insert `octave-continuation-string' before breaking the line |
| 1158 | unless inside a list. Signal an error if within a single-quoted | 1161 | unless inside a list. Signal an error if within a single-quoted |