* lisp/progmodes/ruby-ts-mode.el (ruby-ts--indent-rules):
Fix/change indentation of a continuation method call.
* test/lisp/progmodes/ruby-mode-resources/ruby-ts.rb:
New examples.
;; 2) With paren, 1st arg on next line
((and (query "(argument_list \"(\" _ @indent)")
(node-is ")"))
- (ruby-ts--bol ruby-ts--grand-parent-node) 0)
+ parent-bol 0)
((query "(argument_list \"(\" _ @indent)")
- (ruby-ts--bol ruby-ts--grand-parent-node) ruby-indent-level)
+ parent-bol ruby-indent-level)
;; 3) No paren, ruby-parenless-call-arguments-indent is t
((and ruby-ts--parenless-call-arguments-indent-p (parent-is "argument_list"))
first-sibling 0)
dog = 99
end
+foo1 =
+ subject.update(
+ 1
+ )
+
+foo2 =
+ subject.
+ update(
+ # Might make sense to indent this to 'subject' instead; but this
+ # style seems more popular.
+ 2
+ )
+
# Local Variables:
# mode: ruby-ts
# End: