]> git.eshelyaron.com Git - emacs.git/commit
ruby-mode: Support endless methods (bug#54702)
authorDmitry Gutov <dgutov@yandex.ru>
Sun, 18 Dec 2022 12:01:47 +0000 (14:01 +0200)
committerDmitry Gutov <dgutov@yandex.ru>
Sun, 18 Dec 2022 12:04:17 +0000 (14:04 +0200)
commit6f88de109c837496003296d2b79b0d20c7c3b283
tree0862bcd207707ad280c652de69a466c011809566
parent91dd893e343500b6e3de56aee0207d6f1f8e73bc
ruby-mode: Support endless methods (bug#54702)

* lisp/progmodes/ruby-mode.el (ruby-endless-method-head-re):
New constant.
(ruby-smie-grammar): New token.
(ruby-smie--forward-token, ruby-smie--backward-token):
Recognize it.
(ruby-smie-rules): Indentation support.
(ruby-add-log-current-method): Support here too.

* test/lisp/progmodes/ruby-mode-tests.el
(ruby-add-log-current-method-after-endless-method): New test.

* test/lisp/progmodes/ruby-mode-resources/ruby.rb: New examples.
etc/NEWS
lisp/progmodes/ruby-mode.el
test/lisp/progmodes/ruby-mode-resources/ruby.rb
test/lisp/progmodes/ruby-mode-tests.el