Skip to content

Commit

Permalink
Fix indentation bug emacs-ess#27
Browse files Browse the repository at this point in the history
  • Loading branch information
vspinu committed Mar 30, 2015
1 parent 2b47bab commit b851436
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions lisp/ess-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -1180,10 +1180,11 @@ Return the amount the indentation changed by."
;; move to the beginning of that;
;; possibly a different line
(progn
(if (eq (preceding-char) ?\))
(forward-sexp -1))
;; Get initial indentation of the line we are on.
(current-indentation)))))))))
(when (eq (preceding-char) ?\))
(forward-sexp -2))
(when (not (looking-back "^[ \t]*"))
(forward-sexp -1))
(current-column)))))))))


(defun ess-calculate-indent (&optional parse-start)
Expand Down

0 comments on commit b851436

Please sign in to comment.