
* lisp/progmodes/ruby-mode.el (ruby-block-indent) (ruby-after-operator-indent, ruby-method-call-indent) (ruby-parenless-call-arguments-indent): New options (bug#60186). (ruby-smie-grammar): Specify associativity for "?". (ruby-smie--indent-to-stmt): Add optional argument. * test/lisp/progmodes/ruby-mode-resources/ruby.rb: New cases. * test/lisp/progmodes/ruby-mode-resources/ruby-method-call-indent.rb: * test/lisp/progmodes/ruby-mode-resources/ruby-block-indent.rb: * test/lisp/progmodes/ruby-mode-resources/ruby-after-operator-indent.rb: * test/lisp/progmodes/ruby-mode-resources/ ruby-parenless-call-arguments-indent.rb: New files. * test/lisp/progmodes/ruby-mode-tests.el: Add indentation tests for new files.
33 lines
268 B
Ruby
33 lines
268 B
Ruby
foo
|
|
.asdasd
|
|
.proc do |**args|
|
|
p(**args)
|
|
end
|
|
|
|
foo
|
|
.asdasd
|
|
.proc { |**args|
|
|
p(**args)
|
|
}
|
|
|
|
bar.foo do
|
|
bar
|
|
end
|
|
|
|
bar.foo(tee) do
|
|
bar
|
|
end
|
|
|
|
bar.foo(tee) {
|
|
bar
|
|
}
|
|
|
|
x.foo do
|
|
foo
|
|
end.bar do
|
|
bar
|
|
end
|
|
|
|
# Local Variables:
|
|
# ruby-block-indent: nil
|
|
# End:
|