-
-
Notifications
You must be signed in to change notification settings - Fork 84
"Chuck" should work with position when it is part of a range #741
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
Comments
This will just fix itself once start of and end of are not positions anymore |
Fixed |
Nice! Do we have a test? |
Probably not, but that entire warning logic is removed. There is nothing special about the chuck action or ranges. Start of an end of is now a modifier like all the others. |
Huh yeah you're right. That's kinda cool. Prob still worth adding a test tho, if nothing else so we exercise constructing a range target from empty anchor / active. Should be a 30-second endeavour for whomever records it anyway |
Oh I see I forgot that "chuck" was part of the picture here. Presumably we have "start of past end of" tests. I agree this problem has kind of just become irrelevant now |
But I guess maybe worth testing the removal semantics of whatever kind of target comes out when you construct a range between "start of" / "end of" targets Man I really keep waffling here 😅 |
Fixes #741 ## Checklist - [ ] I have added [tests](https://www.cursorless.org/docs/contributing/test-case-recorder/) - [ ] I have updated the [docs](https://github.com/cursorless-dev/cursorless/tree/main/docs) and [cheatsheet](https://github.com/cursorless-dev/cursorless/tree/main/cursorless-talon/src/cheatsheet) - [ ] I have not broken the cheatsheet
In the following code:
With my cursor at the end of the file I wanted to say
"chuck start of block past start of file"
. However this showed me the error message'Please use "leading" modifier; removal is not supported for "before"'
. This could of course be accomplished using a range anchor exclusion, but I don't see any reason why we shouldn't support this command. The problem is likely that when we combine a two positions to form a range it also becomes a position. This is likely not the correct behavior; it should probably become a plain target or a weak target.The text was updated successfully, but these errors were encountered: