Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

]a followed by Alt-i selects left bracket of arguments. #8581

Open
human154 opened this issue Oct 21, 2023 · 1 comment · May be fixed by #6198
Open

]a followed by Alt-i selects left bracket of arguments. #8581

human154 opened this issue Oct 21, 2023 · 1 comment · May be fixed by #6198
Labels
C-bug Category: This is a bug

Comments

@human154
Copy link

human154 commented Oct 21, 2023

Summary

In Rust, ]a followed by Alt-i selects the left bracket enclosing the arguments.

The bracket being selected seems to be a glitch, as it's not a sub-portion of the initial ]a selection (of the argument and type).

Maybe it would be good to have ]a select the argument name only, instead of the type declaration as well? Then Alt-o could be used to enclose the type as well, if desired.

Reproduction Steps

I tried this:

(In Rust) If I want to select the name of the first argument of a function a few lines below my current location:

]a jumps and selects the first argument name and type of the next function....

Then typing Alt-i, (attempting to select just the argument name), the left bracket of the arguments is selected instead of the expected name of the argument.

Helix log

~/.cache/helix/helix.log
please provide a copy of `~/.cache/helix/helix.log` here if possible, you may need to redact some of the lines

Platform

WSL

Terminal Emulator

Windows terminal

Helix Version

helix 22.12 (6c95411)

@human154 human154 added the C-bug Category: This is a bug label Oct 21, 2023
@human154 human154 changed the title '] a' followed by 'Alt-i' selects left bracket of arguments. ']a' followed by 'Alt-i' selects left bracket of arguments. Oct 21, 2023
@human154 human154 changed the title ']a' followed by 'Alt-i' selects left bracket of arguments. ]a followed by Alt-i selects left bracket of arguments. Oct 21, 2023
@pascalkuthe
Copy link
Member

this is fixed by #6198 I think by ensuring that alt-i only chooses the first child inside the current selection (instead of the first child node in general)

@pascalkuthe pascalkuthe linked a pull request Oct 25, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: This is a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants