Angus Dippenaar
4111d28073
flake update
2023-04-13 13:25:35 +01:00
Lee Cannon
7978485aaf
Merge pull request #1116 from nullptrdevs/nested-struct-init
...
Nested struct init fields completion
2023-04-13 13:14:20 +01:00
Lee Cannon
fe4c9d5a8b
Merge pull request #1122 from arp242/prefer-text
...
Use plain text if the client tells zls it's preferred
2023-04-13 13:13:15 +01:00
Ali Chraghi
42d582c0a2
Update configuration.zig
2023-04-13 09:58:42 +01:00
Martin Tournoij
622efdcd6a
Use plain text if the client tells zls it's preferred
...
LSP clients send a list of supported formats for definition and
completion; the specification says "the order describes the preferred
format of the client."[1]
My client sends:
'hover': {'contentFormat': ['plaintext', 'markdown']},
So it should prefer plaintext, using markdown if that's not supported by
the server. zls behaved slightly different: it would use Markdown if it
appears at all in the list of supported formats.
This fixes it so that it will use plain text if that appears before
'markdown' in the list.
[1]: https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocument_hover
2023-04-13 07:33:43 +02:00
Techatrix
d2287816a7
disable assertions in smallestEnclosingSubrange
2023-04-12 23:44:39 +01:00
nullptrdevs
99cd67e183
Update build to the new zig build API
2023-04-12 23:16:25 +01:00
nullptrdevs
735f884394
Nested struct init fields completion
2023-04-05 10:57:06 -07:00
nullptrdevs
55b1aeb6f7
Avoid accessing inactive union fields in completeDot
( #1115 )
...
As reported on Discord by CodotakuYT:
```zig
fn populate(T: type, index: i32) T {
_ = index;
@typeInfo(T).struct.
}
```
```
thread 17384 panic: access of union field 'ast_node' while field 'param_payload' is active
C:\Users\taoua\zls\src\features\completions.zig:875:61: 0x7ff68070caac in completeDot (zls.exe.obj)
const node_data = nodes_data[local_decl.decl.ast_node];
```
2023-04-05 10:28:21 -04:00
Auguste Rame
7814a05921
Remove format lt 512 diff restriction ( #1109 )
2023-04-04 16:23:44 -04:00
Auguste Rame
0f85c49e46
Add WASI to CI builds ( #1113 )
2023-04-04 16:23:33 -04:00
Auguste Rame
ace6d7f32b
Remove outdated diagnostics check ( #1106 )
2023-04-03 13:42:22 -04:00
Techatrix
b970dd20a3
remove zls.json ( #1108 )
2023-04-03 11:22:51 -04:00
Auguste Rame
471d971d1d
Merge pull request #1000 from Techatrix/stage2-zir
...
Embed AstGen into ZLS
2023-04-01 23:08:40 -04:00
Auguste Rame
99af009232
Disable build file config runs for WASI ( #1102 )
2023-04-01 23:07:38 -04:00
Techarix
018569888f
explain how AstGen will diverge from zig codebase
2023-04-01 23:03:51 +02:00
Techarix
4215edbc33
add support for running ast-check without zig
2023-04-01 23:03:51 +02:00
Techarix
c06cf6e95c
add zig code for generating Zir
2023-04-01 22:44:56 +02:00
Auguste Rame
8b5c649805
Add anytype resolution based on call references ( #1067 )
2023-03-31 11:54:46 -04:00
Auguste Rame
c217502670
Make Analyser use its own arena ( #1101 )
2023-03-29 14:36:32 -04:00
Techatrix
9a7d262e6c
only include snippet completions when enable_snippet is set
2023-03-26 16:20:15 +01:00
Techatrix
90b468ac9f
update snippet data
2023-03-26 16:20:15 +01:00
Techatrix
29037f2f05
disable .fixall
autofix mode
2023-03-26 16:19:38 +01:00
Techatrix
283ca0006d
Apply suggestions from code review
...
Co-authored-by: Lee Cannon <leecannon@leecannon.xyz>
2023-03-26 16:19:00 +01:00
Techatrix
4b042a562a
exclude default cimport declarations from completions
2023-03-26 16:19:00 +01:00
Lee Cannon
f24fcc2b1e
disable cimport resolution ( #1091 )
2023-03-23 13:28:42 -04:00
Techatrix
1e733a8782
fix block label completion test
2023-03-23 15:13:33 +00:00
Techatrix
84228a612e
improve source location of block scope with invalid ast
2023-03-23 15:13:33 +00:00
Techatrix
7e652a5527
refactor document scope creation to be more aware of block expressions
2023-03-23 15:13:33 +00:00
Techatrix
53c7e5bed7
remove TODO's about redefinition errors i favor of ast-check
2023-03-23 15:13:33 +00:00
Techatrix
419527a40d
update handling of some node tags in makeScopeInternal
2023-03-23 15:13:33 +00:00
Techatrix
775c38f5f5
implement document scope creation for array_type_sentinel
2023-03-23 15:13:33 +00:00
Techatrix
72228e2b41
fix printDocumentScope
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
37e3cb463d
generate distinct uris in Context.addDocument
2023-03-23 15:13:14 +00:00
Veikka Tuominen
61b42ca63a
make semantic token configuration an enum
2023-03-23 15:02:12 +00:00
nullptrdevs
e1d90a1a1b
More .
completion
2023-03-23 15:01:23 +00:00
Sage Hane
c89431c625
flake.lock: Update
...
Flake lock file updates:
• Updated input 'flake-utils':
'github:numtide/flake-utils/3db36a8b464d0c4532ba1c7dda728f4576d6d073' (2023-02-13)
→ 'github:numtide/flake-utils/93a2b84fc4b70d9e089d029deacc3583435c2ed6' (2023-03-15)
• Updated input 'nixpkgs':
'github:NixOS/nixpkgs/f5ffd5787786dde3a8bf648c7a1b5f78c4e01abb' (2023-03-03)
→ 'github:NixOS/nixpkgs/c9ece0059f42e0ab53ac870104ca4049df41b133' (2023-03-21)
• Updated input 'zig-overlay':
'github:mitchellh/zig-overlay/09cda6f73587dd4d5dfa8ab8490a94eff5651001' (2023-03-05)
→ 'github:mitchellh/zig-overlay/10704a6e0705a7e5494a6baa8086c4eb88940db0' (2023-03-22)
2023-03-22 14:17:49 +00:00
nullptrdevs
9723a92508
Struct init fields completion.
2023-03-21 17:46:33 +00:00
Techatrix
3c165eabcd
remove boxed null boilerplate
2023-03-21 16:58:05 +00:00
Techatrix
0c333aaa8a
do not print error messages in comptime interpreter tests
2023-03-21 16:58:05 +00:00
Techatrix
334a16ea0c
Merge pull request #1083 from Techatrix/update-build-zig
...
update build.zig
2023-03-21 16:34:07 +00:00
Techatrix
31e133a559
update build.zig
2023-03-20 20:30:51 +01:00
Lee Cannon
a9295769e7
hack latest build changes ( #1077 )
2023-03-18 20:50:26 -04:00
Techatrix
4b034f1afb
Rework file structure ( #1069 )
...
* move language feature files into separate folder
* move code completions into features/completions.zig
* move goto definition/declaration into features folder
* move hover into features folder
* restructure imports
* move selection range into features folder
* restructure request handling tracy call
* add missing features to `zls.zig`
2023-03-17 23:01:41 +01:00
Auguste Rame
3586a7858e
Fix scope creation for label blocks ( #1074 )
2023-03-17 15:02:51 -04:00
Techatrix
0aacb76743
support enums in config_gen ( #1072 )
...
* support enum types in config_gen
* fix typo
2023-03-17 02:27:35 -04:00
Techatrix
8d86d54c0d
Merge pull request #1068 from Techatrix/fix-typos
...
fix typos
2023-03-15 18:57:06 +00:00