* lisp/progmodes/ruby-mode.el (ruby-smie--implicit-semi-p): Handle the
case of the dot in a chained method call being on the following line.
This commit is contained in:
parent
595e113b15
commit
0ea1599d34
3 changed files with 12 additions and 3 deletions
|
@ -1,3 +1,9 @@
|
|||
2013-10-07 Dmitry Gutov <dgutov@yandex.ru>
|
||||
|
||||
* progmodes/ruby-mode.el (ruby-smie--implicit-semi-p): Handle the
|
||||
case of the dot in a chained method call being on the following
|
||||
line.
|
||||
|
||||
2013-10-07 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* electric.el (electric-indent-inhibit): New var.
|
||||
|
|
|
@ -295,7 +295,10 @@ Also ignores spaces after parenthesis when 'space."
|
|||
(and (memq (char-before) '(?\? ?=))
|
||||
(let ((tok (ruby-smie--backward-token)))
|
||||
(or (equal tok "?")
|
||||
(string-match "\\`\\s." tok))))))))
|
||||
(string-match "\\`\\s." tok))))
|
||||
(save-excursion
|
||||
(forward-comment 1)
|
||||
(eq (char-after) ?.))))))
|
||||
|
||||
(defun ruby-smie--redundant-do-p (&optional skip)
|
||||
(save-excursion
|
||||
|
|
|
@ -137,8 +137,6 @@ def foo
|
|||
foo.
|
||||
bar
|
||||
|
||||
# Examples below still fail with `ruby-use-smie' on:
|
||||
|
||||
# https://github.com/rails/rails/blob/17f5d8e062909f1fcae25351834d8e89967b645e/activesupport/lib/active_support/time_with_zone.rb#L206
|
||||
foo
|
||||
.bar
|
||||
|
@ -150,6 +148,8 @@ def foo
|
|||
}
|
||||
}
|
||||
|
||||
# Examples below still fail with `ruby-use-smie' on:
|
||||
|
||||
foo +
|
||||
bar
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue