matlab-scan.el:
(matlab-previous-code-line): In case of no comments, also hand skip over whitespace charts. tests/metest.el: Force empty lines to have no spaces, other lines stay the same. This will exercise bug found above. tests/indents.m: Fix mlint error.
This commit is contained in:
parent
7b49b6f447
commit
9a8784af2a
3 changed files with 9 additions and 2 deletions
|
@ -676,7 +676,10 @@ If LVL2 is nil, compute it."
|
|||
(matlab-scan-stat-inc 'codemiss)
|
||||
(beginning-of-line)
|
||||
(when (not (bobp))
|
||||
(forward-comment -100000) ;; Skip over all whitespace and comments.
|
||||
;; Skip over all comments and intervening whitespace
|
||||
(forward-comment -100000)
|
||||
;; If no comments, then also skip over these whitespace chars.
|
||||
(skip-chars-backward " \t\n")
|
||||
(setq prev (matlab-compute-line-context 1))
|
||||
(setcar (nthcdr mlf-previous-code lvl2) prev)))
|
||||
;; else record a cache hit
|
||||
|
|
|
@ -354,4 +354,6 @@ function debug_cmd_dual ()
|
|||
|
||||
%!!4
|
||||
|
||||
debug_cmd_dual(); %!!4
|
||||
|
||||
end
|
|
@ -317,7 +317,9 @@
|
|||
(goto-char (point-min))
|
||||
(while (not (eobp))
|
||||
(beginning-of-line)
|
||||
(matlab--change-indentation 3) ;;(random 12)
|
||||
(if (looking-at "^\\s-*$")
|
||||
(matlab--change-indentation 0)
|
||||
(matlab--change-indentation 3)) ;;(random 13)?
|
||||
(forward-line 1)
|
||||
)
|
||||
;; And don't delete - leave it to find for the next test.
|
||||
|
|
Loading…
Reference in a new issue