diff options
| author | Aaron Jensen | 2025-11-21 21:20:01 -0800 |
|---|---|---|
| committer | Dmitry Gutov | 2025-11-26 01:31:12 +0200 |
| commit | 16a70518880ef8f54bd853020f1606d3abf04d8e (patch) | |
| tree | a184851e9f787b6e4ad2f12f7638cdfc061baca4 /src | |
| parent | 36f1fde9b9c9db19cfb15eb16ebfc44b3f9c13b9 (diff) | |
| download | emacs-16a70518880ef8f54bd853020f1606d3abf04d8e.tar.gz emacs-16a70518880ef8f54bd853020f1606d3abf04d8e.zip | |
Fix indentation of keyword argument arrays/hashes in ruby-mode
* lisp/progmodes/ruby-mode.el (ruby-smie-rules): Check for ':' and
'=>' as previous tokens, and handle symbols ending with ':' to
properly indent keyword argument arrays and hashes when
ruby-bracketed-args-indent is nil.
* lisp/progmodes/ruby-ts-mode.el (ruby-ts--parent-call-or-bol):
Handle arrays/hashes that are children of 'pair' nodes (keyword
arguments) to ensure consistent indentation.
* test/lisp/progmodes/ruby-mode-resources/ruby-bracketed-args-indent.rb:
Add test cases for keyword argument arrays and hashes with both
symbol-colon and hash-rocket syntax.
When ruby-bracketed-args-indent is nil, arrays and hashes used as
keyword argument values now indent by ruby-indent-level from the
line start, matching the documented behavior and fixing inconsistent
indentation (bug#74517).
(https://lists.gnu.org/archive/html/emacs-devel/2025-11/msg00939.html)
Diffstat (limited to 'src')
0 files changed, 0 insertions, 0 deletions