nullptrdevs
75f0617279
Skip incomplete fn_protos when generating folding ranges ( #958 )
2023-02-02 23:38:09 -05:00
Techatrix
1b3c3defb7
rewrite folding range ( #954 )
2023-02-01 18:29:36 -05:00
Techatrix
767cf7a52d
fix iterateChildren on if ( #951 )
2023-02-01 12:11:45 +00:00
Techatrix
7b3cc1d6d4
Optimize inlay hints ( #948 )
...
* optimize inlay hints
* update iterateChildren
* add tests for nodesAtLoc
2023-01-31 22:41:39 -05:00
Techatrix
eac61ba8be
update data files
2023-01-28 22:42:13 +00:00
Techatrix
3080a5d315
fix config_gen
2023-01-28 22:42:13 +00:00
Techatrix
3c7e9e13ce
better error messages on field access
2023-01-28 19:01:49 +01:00
Techatrix
9cde2495b2
bug fixes
2023-01-28 18:54:16 +01:00
Techatrix
32b70117ef
use SegmentedList
2023-01-28 18:53:42 +01:00
Techatrix
55364f2e2b
do not intern Structs, Enums and Unions
2023-01-28 18:02:29 +01:00
Techatrix
2857237f74
add colon to inlay hint label ( #944 )
2023-01-27 15:59:11 +01:00
Techatrix
e055f9d15c
remove unused capacity from Ast and DocumentStore ( #941 )
2023-01-26 16:57:07 -05: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
Techatrix
9131285db1
improve comptime interpreter stack trace message
2023-01-26 17:14:42 +01:00
Techatrix
ca644d67c1
Merge branch 'master' into intern-pool
2023-01-26 16:16:40 +01:00
Techatrix
fe54fb7cfa
Use new ast helper functions ( #939 )
...
* use new ast helper functions
* use new ast helper functions
* update min build version
* fix merge conflicts
2023-01-24 18:55:38 -05:00
Techatrix
b09c317ae7
bug hunting
2023-01-24 22:07:19 +01:00
Techatrix
d2586f79a1
replace ArrayList with MultiArrayList in DocumentScope ( #938 )
2023-01-24 15:43:48 -05:00
Techatrix
05ad3294f1
use ArrayList for dotCompletions
2023-01-24 17:00:14 +01:00
Techatrix
3577e719fb
equality compare floats with bitcast in InternPool
2023-01-24 16:59:01 +01:00
Techatrix
95139e09ec
move InternPool and encoding into analyser folder
2023-01-23 22:26:56 +01:00
Techatrix
829f4aa9c4
use analyser/completions.zig
for completing comptime interpreter
2023-01-23 22:23:01 +01:00
Techatrix
4b7a434feb
small refactor
2023-01-23 22:21:47 +01:00
Techatrix
497f1e1b23
implement field access in comptime interpreter
2023-01-23 21:29:24 +01:00
Techatrix
9dbae69288
add helper functions to intern pool
2023-01-23 21:28:40 +01:00
Techatrix
d10837dca0
expand dot completions
2023-01-23 21:28:15 +01:00
Álan Crístoffer
0e53ac1328
Partially fixes #907 ( #908 )
2023-01-22 17:52:04 -05:00
Techatrix
4e985e252b
add struct value tests
2023-01-22 22:10:52 +01:00
Techatrix
0817d6008b
redesign InternPool encoding
2023-01-22 21:59:30 +01:00
Álan Crístoffer
903f85ab94
Fix lsp weird behaviour on block cursors ( #891 ) ( #905 )
...
* Fix lsp weird behaviour on block cursors (#891 )
Adds lookahead option to getPositionContext.
2023-01-22 15:47:53 -05:00
Techatrix
5afaf2ae3a
optimize folding range ( #926 )
2023-01-21 13:32:12 -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
Techatrix
1ed8d49b30
fix builtin completions if label_details_support
is false ( #924 )
2023-01-20 19:33:27 -05:00
Techatrix
3085c3e153
implement big int
2023-01-20 22:39:19 +01:00
Techatrix
6d12c640ee
add initial completions on InternPool
2023-01-20 22:24:39 +01:00
Techatrix
ba42fd2bb9
Merge branch 'master' into intern-pool
2023-01-20 22:23:44 +01:00
Techatrix
861e2ffb05
add formatting to recordError
2023-01-20 19:55:26 +01:00
Techatrix
1e73ac91e5
small comptime interpreter refactor
2023-01-20 19:28:25 +01:00
Techatrix
b4ac6142cf
correctly resolve primitive types
2023-01-20 19:20:42 +01:00
Techatrix
34b2643b33
add basic comptime interpreter tests
2023-01-20 17:06:16 +01:00
Techatrix
06fcfcb3db
add internpool to test steps
2023-01-20 17:04:59 +01:00
Techatrix
4a8fe90d23
add coerceInMemoryAllowed integer & float tests
2023-01-20 15:34:49 +01:00
Techatrix
a145dbb616
remove panics from release builds
2023-01-20 15:26:00 +01:00
Techatrix
3d95b203f2
coerce in memory improvements
2023-01-20 15:08:52 +01:00
Techatrix
bdf143eaa6
implement onePossibleValue
2023-01-20 15:08:08 +01:00
Techatrix
666e3b0e7c
add function pointer peer type tests
2023-01-19 21:08:04 +01:00
Techatrix
5c20650143
refactor pointer peer type tests
2023-01-19 19:50:19 +01:00
Techatrix
eca9fc2f20
add expectEqualTypes
2023-01-19 19:49:46 +01:00
Techatrix
ea608a47ea
peer type resolution improvements
2023-01-19 19:16:19 +01:00
Techatrix
1e3d9579ca
improve peer type resolution test failure message
2023-01-19 19:15:52 +01:00
Techatrix
fa5828496e
Generate data files in config_gen.zig ( #903 )
...
* generate data files in config_gen.zig
* remove trailing comma from config.json
* update README.md
* run zig build gen
* handle some unclosed tags
* update data file header
* generate new data files
* remove old data file generators
2023-01-19 01:46:42 -05:00
Techatrix
0c24f8e2a9
update pointer type tests
2023-01-17 20:49:11 +01:00
Techatrix
985cfb6d06
implement union values
2023-01-17 20:37:34 +01:00
Techatrix
30f919d854
optimize hashing and equality checks on structs
2023-01-17 20:36:33 +01:00
Techatrix
2ea97a050b
improve Function memory layout
2023-01-17 20:35:42 +01:00
Techatrix
fb3a4238d7
update tests
2023-01-17 20:32:49 +01:00
Techatrix
407f921ef8
refactor type printing
2023-01-17 20:23:27 +01:00
Techatrix
9e74afada6
show better zig/zls version mismatch messages ( #917 )
...
* show better zig/zls version mismatch messages
* always show message if versions don't match
* ignore patch
2023-01-16 13:49:00 -05:00
Techatrix
af85a9550d
simplify formatting handler ( #916 )
2023-01-16 13:47:55 -05:00
Techatrix
4e4761b34c
fix use after free for builtin completions ( #914 )
2023-01-16 13:47:06 -05:00
Techatrix
8d53a5382d
resolve type of @typeInfo
( #915 )
2023-01-16 13:46:33 -05:00
Techarix
739bd08b7b
fix storage of negative signed integer values
2023-01-16 12:38:35 +01:00
Techatrix
82e3ab9f2e
more tests
2023-01-15 18:25:00 +01:00
Techatrix
45f03ca239
add bit_offset & host_size to Pointer
2023-01-15 15:41:54 +01:00
Techatrix
bdf207a821
small refactor on ComptimeInterpreter
2023-01-14 21:49:27 +01:00
Techatrix
d49979d002
remove arena from ComptimeInterpreter
2023-01-14 21:30:52 +01:00
Techatrix
969efdfba0
more tests
2023-01-14 21:27:55 +01:00
Techatrix
5dca172c31
small cleanup
2023-01-14 19:51:44 +01:00
Techatrix
1456bfa1c6
refactor InternPool KeyAdapter
2023-01-14 19:17:06 +01:00
Techatrix
04d281340c
restructure ComptieInterpreter tests
2023-01-14 14:08:15 +01:00
Techatrix
98899ed0cf
some ComptieInterpreter work
2023-01-14 14:07:52 +01:00
Alex Kladov
61fa98065f
fix use after free ( #911 )
2023-01-11 20:18:37 +00:00
Lee Cannon
20d29fd491
move log overrides into std_options
( #902 )
2023-01-10 16:52:03 -05:00
Techatrix
4423a5face
improve memory allocations ( #889 )
...
* improve memory allocations
* Update src/main.zig
Co-authored-by: erikarvstedt <36110478+erikarvstedt@users.noreply.github.com>
* add missing 0x21
Co-authored-by: erikarvstedt <36110478+erikarvstedt@users.noreply.github.com>
2023-01-09 11:09:36 -05:00
Auguste Rame
21b103c158
Fix build runner cwd causing relative @src ( #898 )
...
Co-authored-by: Nameless <truemedian@gmail.com>
Co-authored-by: Nameless <truemedian@gmail.com>
2023-01-08 23:13:20 -05:00
Techatrix
68790c73a7
return from main instead of calling exit ( #894 )
2023-01-08 23:13:02 -05:00
Techatrix
e9b364772d
fix returning freed memory in formattingHandler ( #890 )
2023-01-07 16:33:10 -05:00
Techatrix
54e7d1da8b
fix compile errors when targeting wasm ( #886 )
...
* fix compile errors when targeting wasm
* update known-folders
2023-01-07 15:21:20 -05:00
Techatrix
3f2700eaa5
improve completion on error and enums ( #887 )
2023-01-06 13:59:20 -05:00
Techatrix
27d91d100f
more tests
2023-01-06 15:02:45 +01:00
Techatrix
909424cada
error set type formatting
2023-01-06 15:01:48 +01:00
Techatrix
650eaeb66c
implement anyframe->T
2023-01-06 14:38:28 +01:00
Techatrix
f0c888188a
refactor and basic struct/union value implementation
2023-01-06 14:12:29 +01:00
mlugg
b163be51d3
Fix crash when using nvim-lspconfig ( #884 )
...
Apparently, nvim reports its code action kinds using both the actual
strings (e.g. "refactor.extract") and the enumeration names (e.g.
"RefactorExtract"). I don't know why this is done - possibly an attempt
at compatibility with non-compliant server implementations? Regardless,
this was causing a crash on init (when tres tried to parse an
initializaiton message), which is easily fixed by just supporting those
enumeration values.
Resolves : #867
2023-01-05 13:50:02 -05:00
Techatrix
8828ff117d
more comptime interpreter work
2023-01-04 11:11:48 +01:00
Techatrix
651955399e
remove namespace and decl from intern pool
2023-01-04 11:10:46 +01:00
Techatrix
5598ad032b
partially implement peer type resolution for pointer types
2023-01-04 09:53:48 +01:00
Techatrix
475da58895
finish and test peer type resolution among integers and floats
2023-01-04 06:07:39 +01:00
Techatrix
d56a274c16
Merge branch 'master' into intern-pool
2023-01-04 04:42:06 +01:00
Auguste Rame
20baa592eb
Add error return trace ( #882 )
2023-01-03 15:37:59 +00:00
Techatrix
a574ac68ba
use more explicit error sets ( #880 )
2023-01-03 10:21:58 -05:00
Techatrix
c718e12d16
Autofix improvements ( #879 )
...
* improve autofix stability and client support
* run zig fmt
2023-01-02 14:59:01 -05:00
Techatrix
9badc745c5
remove setup wizard ( #878 )
...
* remove setup wizard
* add back findZig function
2023-01-02 13:54:13 -05:00
Techatrix
b95d5095af
enable all capabilities by default ( #877 )
2023-01-02 04:02:28 -05:00
Techatrix
3449269fd3
Add a replay feature to zls ( #857 )
...
* add config options for `zls --replay`
* implement `zls --replay`
* remove carriage return from zls replay files
* add missing arguments for Server.init in tests
2022-12-31 01:45:45 -05:00
Techatrix
417bf9bd0a
add vscode config generation to zig build gen
( #862 )
...
* add vscode config generation to `zig build gen`
* correctly handle removing configs in config_gen.zig
* update log messages in config_gen.zig
2022-12-30 18:45:31 -05:00
Techatrix
d86d05d969
fix ast-check with single error ( #865 )
2022-12-30 18:43:40 -05:00
Techatrix
94ec3a0a86
Debugging utilities ( #860 )
...
* add debug printing for Ast and DocumentScope
* add optional failing allocator
2022-12-30 18:42:53 -05:00
Techatrix
f473088b64
fix crashes found through fuzzing ( #866 )
2022-12-30 18:42:28 -05:00
Techatrix
c88562ca78
optimize build.zig
discovery ( #863 )
2022-12-29 18:21:26 -05:00