diff options
| author | Leo Liu | 2013-05-13 08:07:18 +0800 |
|---|---|---|
| committer | Leo Liu | 2013-05-13 08:07:18 +0800 |
| commit | 2aeb3a1dbaca57eb0fa38aa89f08a66563272041 (patch) | |
| tree | caf60c7b9914a5a96d5a1dec081c5b4cd9313fc0 | |
| parent | 44aa9ee6d2c451df9bffa7ff302c624b88d701b4 (diff) | |
| download | emacs-2aeb3a1dbaca57eb0fa38aa89f08a66563272041.tar.gz emacs-2aeb3a1dbaca57eb0fa38aa89f08a66563272041.zip | |
* progmodes/octave.el (octave-indent-comment): Fix the indentation
of ### or %%%.
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/progmodes/octave.el | 11 |
2 files changed, 12 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5a2d5c991d4..62f094dc6e4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2013-05-13 Leo Liu <sdl.web@gmail.com> | ||
| 2 | |||
| 3 | * progmodes/octave.el (octave-indent-comment): Fix the indentation | ||
| 4 | of ### or %%%. | ||
| 5 | |||
| 1 | 2013-05-12 Leo Liu <sdl.web@gmail.com> | 6 | 2013-05-12 Leo Liu <sdl.web@gmail.com> |
| 2 | 7 | ||
| 3 | * progmodes/octave.el (inferior-octave-startup): Store the value | 8 | * progmodes/octave.el (inferior-octave-startup): Store the value |
diff --git a/lisp/progmodes/octave.el b/lisp/progmodes/octave.el index 75c2508dd30..f00347d319a 100644 --- a/lisp/progmodes/octave.el +++ b/lisp/progmodes/octave.el | |||
| @@ -434,10 +434,13 @@ Non-nil means always go to the next Octave code line after sending." | |||
| 434 | "A function for `smie-indent-functions' (which see)." | 434 | "A function for `smie-indent-functions' (which see)." |
| 435 | (save-excursion | 435 | (save-excursion |
| 436 | (back-to-indentation) | 436 | (back-to-indentation) |
| 437 | (when (and (not (octave-in-string-or-comment-p)) | 437 | (cond |
| 438 | (looking-at-p "\\s<\\(?:[^{}]\\|$\\)") | 438 | ((octave-in-string-or-comment-p) nil) |
| 439 | (not (looking-at-p "\\s<\\s<"))) | 439 | ((looking-at-p "\\s<\\{3,\\}") |
| 440 | (comment-choose-indent)))) | 440 | 0) |
| 441 | ((and (looking-at-p "\\s<\\(?:[^{}]\\|$\\)") | ||
| 442 | (not (looking-at-p "\\s<\\s<"))) | ||
| 443 | (comment-choose-indent))))) | ||
| 441 | 444 | ||
| 442 | 445 | ||
| 443 | (defvar octave-font-lock-keywords | 446 | (defvar octave-font-lock-keywords |