Issue #10318 has been updated by Nobuyoshi Nakada.


Welcome to the underground holy war. ;)
You may know that ruby-style.el has `(indent-tabs-mode . t)`.

----------------------------------------
Feature #10318: [PATCH 0/n] Let underscore be positionally matched arg to omit binding obvious variable.
https://bugs.ruby-lang.org/issues/10318#change-49222

* Author: gogo tanaka
* Status: Open
* Priority: Normal
* Assignee: 
* Category: 
* Target version: Next Major
----------------------------------------
Im so sorry for just proposing this future without PATCH right now...

(I suppose it contains too much issues.)

After some discussions, let me implement this future.

Of course I need to obtain your consent.

Anyway, I want to let underscore be positionally matched arg and omit to binding obvious variable when it comes to proc, lambda and block .

```
# let items be a Array of String. (e.g. items = ['foo', 'bar', 'foobar']

# Before
items.select { |item| item.include?('foo') }

# After
items.select { _.include?('foo') }

```

Even if block has more than 2 args, I want to omit one of them.

(I know it has much pain ... just idea)

```
# let nums be a Array of Integer. (e.g. nums = [1, 2, 3, 4]

# Before
nums.inject { |sum, num| sum + num }

# After
nums.inject { |sum| sum + _ }
# It seems to difficult to hundle .. but looks aesthetic or understandable.
```

Let me know how do you think about it or what problem is.

thank you. gogo.


---Files--------------------------------
convert_tabs_to_spaces.patch (29.3 KB)


-- 
https://bugs.ruby-lang.org/