Before, the code lexed only a prefix of the line up to cursor position.
Now, we lex the entire line, and do look at the token just after the
cursor.
This subtly changes sematncih of `getPostionContext`: now it is becomes
oblivious of the _exact_ position of the cursor and returns the whole
token at cursor's position.
I believe this is semantically right approach -- _most_ of the callsite
should not worry at all about such details. Something like completion
_might_ want to know more, but it's better to make that call site's
problem.
It might be the case that some existing code relies on the past
behavior. It's hard to tell though -- we don't have a lot of tests for
_features_, and changes to unit-tests don't explain if the changes are
meaningful for user-observable behavior or not.
In general, for LSP-shaped thing, I feel that the bulk of testing should
be focused on end-to-end behaviors....
* fix missing backslash
* fix: zls escaping colon to %3A on URIs
ZLS escapes a colon char ":" as "%3A" when encoding file paths to URIs
When decoding, need to make the target string 2 character shorter
to compensate for length decrease when replacing %3A with :
* add new failing test because of resize()
* revert changes to %3A handling - problem seems to be with allocator.resize
* switch to realloc
* Fix test failures, revert errdefer->defer
* platform-specific URI tests
URI parsing is highly platform-specific
run Unix-style (file:///home/main.zig) on non-Windows test runners,
run Windows-style (file://c%3A/main.zig) on Windows test runners
* fix compiler errors when using self-hosted
* move parameters into builder struct
* simplify code when using self hosted
* fix stage2 error `cast discards const qualifier`
* correctly return after finding method
* fix position context tests on self hosted
* remove unnecessary comptime in position context tests