diff --git a/lib/std/core/array.c3 b/lib/std/core/array.c3 index 6ca1d501e..abb808e34 100644 --- a/lib/std/core/array.c3 +++ b/lib/std/core/array.c3 @@ -79,7 +79,7 @@ macro concat(arr1, arr2, Allocator allocator) @nodiscard @require @typekind(arr1) == SLICE || @typekind(arr1) == ARRAY @require @typekind(arr2) == SLICE || @typekind(arr2) == ARRAY @require @typeis(arr1[0], $typeof(arr2[0])) "Arrays must have the same type" - @ensure result.len == arr1.len + arr2.len + @ensure return.len == arr1.len + arr2.len *> macro concat_new(arr1, arr2, Allocator allocator = allocator::heap()) @nodiscard { @@ -95,7 +95,7 @@ macro concat_new(arr1, arr2, Allocator allocator = allocator::heap()) @nodiscard @require @typekind(arr1) == SLICE || @typekind(arr1) == ARRAY @require @typekind(arr2) == SLICE || @typekind(arr2) == ARRAY @require @typeis(arr1[0], $typeof(arr2[0])) "Arrays must have the same type" - @ensure result.len == arr1.len + arr2.len + @ensure return.len == arr1.len + arr2.len *> macro tconcat(arr1, arr2) @nodiscard => concat(arr1, arr2, allocator::temp()); diff --git a/releasenotes.md b/releasenotes.md index 99e124a60..f4d89707e 100644 --- a/releasenotes.md +++ b/releasenotes.md @@ -25,6 +25,7 @@ - Deprecate `fn void! main() type main functions. - Deprecate old `void!` @benchmark and @test functions. - Allow test runners to take String[] arguments. +- Added `--lsp` output. ### Fixes - Fix case trying to initialize a `char[*]*` from a String. diff --git a/src/build/build.h b/src/build/build.h index b7af75318..d1437c885 100644 --- a/src/build/build.h +++ b/src/build/build.h @@ -491,6 +491,7 @@ typedef struct BuildOptions_ bool emit_asm; bool benchmark_mode; bool test_mode; + bool lsp_mode; bool no_entry; bool no_obj; bool no_headers; @@ -600,6 +601,7 @@ typedef struct bool generate_test_runner; bool benchmark_output; bool test_output; + bool lsp_output; bool output_headers; bool output_ast; bool lex_only; diff --git a/src/build/build_options.c b/src/build/build_options.c index 0b559982c..66e053e6a 100644 --- a/src/build/build_options.c +++ b/src/build/build_options.c @@ -125,7 +125,9 @@ static void usage(bool full) PRINTF(" --optsize=