Fix comment continuation on return in C/C++/Java

This commit is contained in:
Henrik Lissner 2015-05-05 21:13:56 -04:00
parent d0cc583e19
commit 36da5e44ad

View file

@ -115,9 +115,9 @@ spaces on either side of the point if so. Resorts to
((sp-point-in-string)
(newline))
((sp-point-in-comment)
(if (eq major-mode 'js2-mode)
(js2-line-break)
(indent-new-comment-line)))
(t
(newline-and-indent)
(ignore-errors (indent-sexp)))))
(cond ((eq major-mode 'js2-mode)
(js2-line-break))
((-contains? '(c-mode c++-mode objc-mode java-mode) major-mode)
(c-indent-new-comment-line))
(t (indent-new-comment-line))))
(t (newline-and-indent))))