Commit Graph

74 Commits

Author SHA1 Message Date
nullptrdevs
bd539ae989
[std.zig.] parse(alloc, src) -> Ast.parse(alloc, src, Ast.Mode) (#966)
* Work in Zig's breaking changes (build sys apis)

* [`std.zig.`] `parse(alloc, src)` -> `Ast.parse(alloc, src, Ast.Mode)`
2023-02-04 18:19:24 +00:00
Techatrix
e055f9d15c
remove unused capacity from Ast and DocumentStore (#941) 2023-01-26 16:57:07 -05:00
Alex Kladov
61fa98065f
fix use after free (#911) 2023-01-11 20:18:37 +00: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
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
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
c88562ca78
optimize build.zig discovery (#863) 2022-12-29 18:21:26 -05:00
Techatrix
978e41b8a5
always use scoped logs instead of default (#864) 2022-12-29 18:20:12 -05:00
Techatrix
ebe3ba1471
Memory lifetime fixes (#861)
* fix memory lifetime issues

* more memory lifetime issue fixes
2022-12-29 00:59:19 -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
Techatrix
941882371c
fix memory lifetime issues (#851) 2022-12-27 00:52:15 -05:00
Techatrix
375daba743
improve behavior if zig_exe_path is not set (#830) 2022-12-17 03:03:05 -05:00
Techatrix
e1973afafc
fix cimport duplicate messages & crash (#828) 2022-12-16 15:24:03 -05:00
Lee Cannon
c3256c00e7
pass correct zig-cache path (#789) 2022-11-29 17:50:09 -05:00
Auguste Rame
c8dffc1f9b
Some comptime interpreter fixes 2022-11-10 20:51:02 -05:00
Auguste Rame
599c134593
Imports, cross-boundary resolution; can import std but dies on missing builtins / lang features 2022-11-08 14:37:13 -05:00
Auguste Rame
da00751726
Field access, function calls based on function value 2022-11-08 14:37:13 -05:00
Techatrix
862d30055a
fix cimport completion (#722) 2022-10-28 00:38:36 -04:00
Techatrix
88750d2529
fix allocator mismatch in tagStoreCompletionItems (#717) 2022-10-25 23:22:15 -04:00
Techatrix
2755d8d8b7 simplify dependency collection in references.zig 2022-10-17 21:20:27 +02:00
Techatrix
8fb7379d71 return null if file can't be read in documentstore 2022-10-17 20:46:31 +02:00
Techatrix
2158a201ad add separate function for loading handles with getOrLoadHandle 2022-10-17 20:43:11 +02:00
Techatrix
89be8e0211 return const Handle from getHandle 2022-10-17 20:33:37 +02:00
Techatrix
ba007b3558 fix tagStoreCompletionItems 2022-10-17 20:25:51 +02:00
Techatrix
4316524226 add more tracy calls in documentstore 2022-10-17 20:23:51 +02:00
Techatrix
9f688cf4ed simplify tagStoreCompletionItems 2022-10-17 20:20:34 +02:00
Techatrix
0cfc792849 load handles on demand instead of ahead of time 2022-10-16 17:26:06 +02:00
Techatrix
06ba47d460 improve document of DocumentStore.zig 2022-10-10 20:01:54 +02:00
Techatrix
aff2c3234f fix relative_builtin_path option 2022-10-10 19:43:50 +02:00
Techatrix
420e7f2fef correctly resolve import("builtin") 2022-10-10 19:22:54 +02:00
Techatrix
e024a9ec38 finish document store garbage collection 2022-10-09 01:50:03 +02:00
Techatrix
ce7afe03f2 correctly exclude builtin.zig from build.zig search 2022-10-09 01:48:51 +02:00
Techatrix
5d748767e9 mark DocumentStore & Handle const 2022-10-05 13:40:11 +02:00
Techatrix
dab7eb81cc reimplement document store 2022-10-05 13:23:38 +02:00
Techatrix
a9a1fad13e
remove types.TextDocument (#693)
* remove types.TextDocument

* resolve compile errors because of previous merge
2022-09-30 20:45:45 -04:00
Techatrix
51356517a9
Self hosted fixes (#682)
* 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
2022-09-30 00:04:55 -04:00
Matt Knight
6ec6d4ea36
Revamp bulid.zig discovery (#688)
* walk down tree instead of up for build.zig discovery

* account for windows URIs in tests
2022-09-28 23:12:34 -04:00
J.C. Moyer
295669297a Remove unnecessary indirection 2022-09-28 10:10:27 -04:00
J.C. Moyer
cbc6feeb76 Allocate build_runner args directly 2022-09-28 08:33:48 -04:00
J.C. Moyer
399fa7fd09 Move build options out of parse result instead of copying 2022-09-28 08:32:19 -04:00
J.C. Moyer
0b0e6a7cb9 Support for user-configurable build options 2022-09-28 04:14:49 -04:00
Lee Cannon
137edcd527
use StringArrayHashMap to remove duplicate include paths 2022-09-26 22:01:00 +01:00
Techatrix
e9e9571fe5
avoid config copy for document store (#669) 2022-09-21 21:31:48 -04:00
Techatrix
cf52fd8190 report cImport failure using textDocument/publishDiagnostics 2022-09-19 19:53:41 +02:00
Techatrix
e28549fa7d
Completely overhaul offsets.zig (#643)
* completely overhaul offsets.zig
2022-09-16 00:33:49 +00:00
Techatrix
e6238e3354
improve width of log prefix (#649) 2022-09-13 16:12:32 -04:00
nullptrdevs
481903e72a fix: fix an attempt to use null value in DocumentStore.resolveImport
caused by missing files or weird file path starting
e.g.
```
pub const abc = @import(".////abc.zig");
```
2022-08-25 15:52:07 -07:00
Techatrix
dc3199cffa unmanage all the code 2022-08-23 12:44:26 +02:00
Lee Cannon
eb60f75413
workaround zig tarball bug (#599) 2022-08-23 00:01:44 +02:00