On 01.01.2020 22:15, Chet Ramey wrote:
On 12/29/19 8:31 PM, Andrey Butirsky wrote:
On 30.12.2019 04:26, Chet Ramey wrote:
That's the thing: it's not a bug. Function name matching is
case-insensitive, and always has been. This goes back as far as I can easily
check right now, and even predates vi mode.
So how about my second suggestion then, to eliminate the confusion?
Swap
{ "vi-bword", rl_vi_bword },
to
{ "vi-bword", rl_vi_bWord },
A couple of things. One, that would be wrong, since you want "vi-bWord" to
map to `rl_vi_bWord' and "vi-bword" to map to `rl_vi_bword' for
consistency if nothing else. Two, how would that `eliminate the confusion'?
The result might be what you want, but it would change the behavior for
everyone who wants the historical behavior, breaking backwards
compatibility and introducing additional issues.
I'm not sure you understood me what the real problem is.
Of course I want "vi-bWord" to map to `rl_vi_bWord' and "vi-bword" to
map to `rl_vi_bword', but the problem is bash just doesn't work that way
- instead, it really maps "vi-bword" to `rl_vi_bWord', but this behavior
is hidden and not obvious from the code (I was caught to it by myself
twice, and both times it was a pain to dig it out). So if the mapping
would correspond to its real behavior, it would eliminate the confusion,
just it.
Considering the historical behavior, you said it always been
case-insensitive, so I suppose it just wouldn't change.