fn ⌃ ⌥
0baae921ed
Add completion test
2023-06-24 10:14:58 -07:00
Techatrix
a16fb19797
improve self param detection in inlay hints ( #1258 )
2023-06-24 02:25:12 +01:00
FalsePattern
cf211cd599
update casting builtins
2023-06-21 17:08:10 +02:00
Joe Williams
83c9a7b493
autofix now handles comments in the event of a newline w/ comments ( #1236 )
...
* autofix now handles comments in the event of a newline w/ comments
* oob check
* continue statements so we don't waste time checking things we know
* added a skip for if the characters are a comment
* convert to switch for readability
2023-06-15 12:53:33 -07:00
Lee Cannon
4d0e1afb72
Merge pull request #1233 from Techatrix/enum-completion
...
set Enum completion kind to .EnumMember
2023-06-09 23:20:42 +01:00
Techatrix
c446087231
set Enum completion kind to .EnumMember
2023-06-09 23:35:27 +02:00
Techatrix
77e39a8da8
clear using_trail when calling resolveUse
...
fixes #1231
2023-06-09 23:13:36 +02:00
Lee Cannon
5d53f0104f
Merge pull request #1209 from Vexu/semantic-tokens
...
Semantic token adjustments
2023-05-30 21:24:58 +01:00
Lee Cannon
fa0793596f
Merge pull request #1215 from Techatrix/refactor-doc-scope
...
Refactor document scope generation
2023-05-30 21:05:26 +01:00
Techatrix
cc8fb14906
add tests for autofix code actions
2023-05-30 18:46:37 +02:00
Techatrix
9f9bf9eba8
include enum fields in enum completion set
2023-05-30 00:02:01 +02:00
Techatrix
6f7f9dab9d
refactor document scope creation with ast.iterateChildren
2023-05-30 00:02:01 +02:00
Veikka Tuominen
cda0fd4386
rewrite semantic token types union and opaque as type
...
The default themes on vscode color these the same as all other identifiers.
2023-05-29 12:57:18 +03:00
Techatrix
5cc7b1341e
skip std module resolution test on webassembly target
2023-05-21 21:48:46 +02:00
Techatrix
6f0907bc16
fix semantic tokens on union and enum container fields
2023-05-21 21:48:46 +02:00
Techatrix
cde544125a
bring semantic token types and modifiers closer to predefined ones
2023-05-21 21:48:46 +02:00
Techatrix
d9965c7834
fix semantic tokens on if capture by ref
2023-05-21 21:48:46 +02:00
Techatrix
498517ba71
replace semantic token type .field with .property
2023-05-21 21:48:46 +02:00
Techatrix
ae5fa110b5
test and simplify semantic tokens on function call
2023-05-21 21:48:46 +02:00
Techatrix
3fefcfb398
simplify semantic token comment handling
2023-05-21 21:48:46 +02:00
Techatrix
3500aa7a76
update to new std.json api ( #1191 )
...
* update lsp.zig
* update to new `std.json` api
* update min zig version
* fix json api
2023-05-18 20:46:22 -04:00
Rekai Musuka
ec50d33241
fix: update test case involving @memcpy
2023-05-04 00:51:13 -05:00
Lee Cannon
825cbd2e07
Merge pull request #1142 from Techatrix/iterate-asm
...
implement `iterateChildren` on asm
2023-04-17 23:03:15 +01:00
Techarix
c0498fffa1
add completion tests on struct init fields
2023-04-17 23:25:20 +02:00
Techatrix
92eaa22c30
implement iterateChildren
on asm
2023-04-17 23:03:54 +02:00
Techatrix
1e733a8782
fix block label completion test
2023-03-23 15:13:33 +00:00
Techatrix
1df17e8aa5
enable successful references test
2023-03-23 15:13:14 +00:00
Techatrix
6530fe01c4
implement testing for cross-file references
2023-03-23 15:13:14 +00:00
Techatrix
5944db49b3
add multi-file support to ErrorBuilder
...
colorize ErrorBuilder output
2023-03-23 15:13:14 +00:00
Techatrix
973d33d435
expand semantic token test coverage
2023-03-14 14:56:11 +00:00
Techatrix
a959f161e9
find references on test decl with identifier name ( #1051 )
2023-03-12 01:24:54 -05:00
Techatrix
ab23ff3616
Optimize document symbols ( #1050 )
...
* optimize document symbol generation
* match folding range index to position conversion and documentation to document symbol's
* skip function decls with no name
* skip document symbol field in opaque type
2023-03-12 01:24:42 -05:00
Techatrix
1fb7bfc63f
update failing semantic tokens test
2023-03-06 09:32:03 -08:00
Techarix
4b0da6f6ae
fix folding range on multi line function declaration
2023-02-25 10:58:29 -08:00
Techarix
97f7fd77c6
fix folding range on structs with doc comment on first field
2023-02-25 10:58:29 -08:00
Techatrix
0f77fd5b0e
add multi object for loop support ( #1011 )
...
* run `zig fmt`
* add support for multi object for loops
* add completion tests on multi object for loops
* update minimum zig build version
* use multi object for loops in codebase
* Update tres to latest version
* fix panics when generating document scope on invalid for loops
2023-02-21 17:11:35 -05:00
Alex Kladov
73d6264cab
Fix missing nodes in outline ( #990 )
...
* Remove some boilerplate from test
* Fix missing nodes in outline
2023-02-11 14:20:01 -05:00
Alex Kladov
0d3b0e9965
Remove some boilerplate from test ( #988 )
2023-02-11 14:19:37 -05:00
Alex Kladov
0e5e1fdb8a
add testing infra for textDocument/documentSymbol ( #987 )
...
* add testing infra for textDocument/documentSymbol
* add failing test for 986
2023-02-11 01:31:06 -05:00
Techatrix
1b3274aa9c
simplify symbol references handler ( #978 )
2023-02-06 04:25:29 -05:00
Techatrix
1b3c3defb7
rewrite folding range ( #954 )
2023-02-01 18:29:36 -05:00
Techatrix
2857237f74
add colon to inlay hint label ( #944 )
2023-01-27 15:59:11 +01:00
Techatrix
6019eff13e
Fuzzer fixes ( #940 )
...
* better handling of container_decl_arg_trailing
* ignore semantic token when moving backwards
* use custom ast functions instead of from std
2023-01-26 16:04:49 -05:00
Aleksey Kladov
ea05916e69
Goto definition works when the cursor is at the start of the identifier.
...
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....
2023-01-21 18:31:26 +00:00
Alex Kladov
a6b7a35367
add tests for textDocument/Definition ( #900 )
2023-01-10 09:40:40 +00:00
Techatrix
3f2700eaa5
improve completion on error and enums ( #887 )
2023-01-06 13:59:20 -05:00
Techatrix
f473088b64
fix crashes found through fuzzing ( #866 )
2022-12-30 18:42:28 -05:00
Techatrix
61c0981294
Use zig-lsp-codegen ( #850 )
...
* add lsp.zig
* change references from types.zig to lsp.zig
* remove types.zig and requests.zig
* add tres as a submodule
* transition codebase from types.zig to lsp.zig
* update lsp.zig
* completely overhaul message handler
* fix memory errors
* partially transition tests to lsp.zig
* update lsp.zig
* more test fixes
* disable failing tests
* fix message handling bugs
* fix remaining tests
* access correct union in diff.applyTextEdits
* more message handler fixes
* run zig fmt
* update tres submodule
* fix memory access to freed memory
* simplify initialize_msg for testing
* check if publishDiagnostics is supported
2022-12-27 01:47:57 -05:00
Ryan Liptak
f6c15ac10c
semantic_tokens: Fix handleComments not evaluating the last byte ( #844 )
...
Fixes #842
2022-12-22 22:27:38 -05:00
Auguste Rame
1e99692d5c
Enable stage2 ( #810 )
2022-12-07 11:39:46 -05:00