Commit graph

18563 commits

Author SHA1 Message Date
yuyi
a3f6fd5d2f
ast: cleanup in stringify_fn_after_name() (#22473) 2024-10-10 15:24:49 +03:00
yuyi
d3b380b48b
cgen: fix option if expr with noreturn fn call (fix #22467) (#22470) 2024-10-10 12:23:28 +03:00
yuyi
51b471b060
all: replace enum field name 'xxx_' with 'xxx' (#22469) 2024-10-10 09:17:19 +03:00
yuyi
b97b2b1c9c
all: replace enum field name struct_ with struct (#22466) 2024-10-10 04:41:15 +03:00
Felipe Pena
72b48047b5
checker: add scope validation for struct (fix #22437) (#22449) 2024-10-09 22:48:28 +03:00
yuyi
4c82b0125e
parser: allow enum field names being the same as V keywords (#22456) 2024-10-09 20:57:00 +03:00
Delyan Angelov
3e6fc364a8
transformer: optimise calls to write string with simple interpolations, implement -d trace_transformer (#22188) 2024-10-09 19:41:48 +03:00
Felipe Pena
8fcf3d75ba
cgen: fix codegen for multi return with array fixed (fix #22451) (#22454) 2024-10-09 18:00:49 +03:00
Felipe Pena
875faaff0f
checker: fix missing check for escape char on unicode checker (#22462) 2024-10-09 16:49:51 +03:00
Felipe Pena
98f66d803a
picoev: fix wrong return on listen failure (#22463) 2024-10-09 16:38:52 +03:00
Carlos Esquerdo Bernat
7e17b9abba
checked: change wording of comment vweb -> veb (#22458) 2024-10-09 14:31:58 +03:00
Alexander Medvednikov
e1480b61dd all: more unsafe warnings => errors 2024-10-09 00:52:17 +03:00
kbkpbot
0224581bc6
math.big: improve the performance of left_shift_digits_in_place and right_shift_digits_in_place (#22450) 2024-10-08 21:48:26 +03:00
Felipe Pena
ef72f97b96
json: fix encode/decode of fixed arrays (fix #22369) (#22448) 2024-10-08 19:31:34 +03:00
Felipe Pena
e14bc6077b
checker: fix struct array generic field (fix #22406, second try) (#22443) 2024-10-08 18:59:59 +03:00
yuyi
4d74d7296a
parser: fix generics method chaining call (#22447) 2024-10-08 12:32:28 +03:00
Tim Marston
9d164d07b3
checker: don't cast match branch structs to IError, when the return type of a function is !SumType (#22444) 2024-10-08 10:04:27 +03:00
Carlos Esquerdo Bernat
eb57746a59
x.json2: allow parsing a value from a multidimensional array in map_from (#22442) 2024-10-08 09:49:45 +03:00
Delyan Angelov
c16cde7b83
v.builder: support injected options with newlines, coming from #flag directives, when -no-rsp is used 2024-10-08 08:58:08 +03:00
Jose Mendoza
75658415f1
builtin: add string.wrap method + tests (#22441) 2024-10-08 07:14:32 +03:00
Alexander Medvednikov
e1b842a8fa Revert "cgen: fix codegen for struct array with generic field (fix #22406) (#22413)"
This reverts commit 482aad5c18.
2024-10-07 23:05:33 +03:00
Felipe Pena
482aad5c18
cgen: fix codegen for struct array with generic field (fix #22406) (#22413) 2024-10-07 22:57:27 +03:00
Felipe Pena
914169ed4b
checker: fix missing check for generic array type without concrete types (fix #22414) (#22416) 2024-10-07 19:49:47 +03:00
Carlos Esquerdo Bernat
0073f097a7
v.ast: comment on the IndexExpr.is_farray field (#22438) 2024-10-07 19:26:22 +03:00
Delyan Angelov
d3c3c391ca
checker: reduce allocations part 2 (#22434) 2024-10-07 17:07:31 +03:00
yuyi
184a86343e
all: cleanup resolve_generic_to_concrete() and related methods (#22433) 2024-10-07 15:12:28 +03:00
Swastik Baranwal
f4c04844b2
checker: disallow iterating through .params, for types that are not a function/method (#22428) 2024-10-07 12:38:24 +03:00
Delyan Angelov
5a33c36ab7
checker: reduce allocations in Checker.method_call (#22432) 2024-10-07 11:27:18 +03:00
yuyi
3736e51e62
ast, parser: fix generic fn type with defferent generic type call (#22431) 2024-10-07 11:05:31 +03:00
kbkpbot
309c8d3778
strconv: fix e/g format (fix #22424) (#22430) 2024-10-07 08:43:04 +03:00
Delyan Angelov
502442ad00
os: implement os.data_dir(), os.state_dir(), os.local_bin_dir() + tests (#22426) 2024-10-07 07:23:50 +03:00
Alexander Medvednikov
2b52153c14 all: make 0 => unsafe { nil } an error, not a notice 2024-10-07 01:54:19 +03:00
Alexander Medvednikov
a2d385aee3 parser: allow struct definitions inside functions 2024-10-06 22:40:14 +03:00
Delyan Angelov
4f9df0da72
builtin: unify memory allocation error handling, and avoid string interpolation, when allocation failed (#22423) 2024-10-06 20:56:58 +03:00
kbkpbot
491d6f4955
strconv: fix remove_tail_zeros bug (fix #22421) (#22422) 2024-10-06 16:48:08 +03:00
Swastik Baranwal
6ed176515d
checker: disallow blank ident in const and global decl (#22415) 2024-10-06 16:36:50 +03:00
Delyan Angelov
93d3278a5a
v.util: fix handling of spaces before the second argument of $d(name, value) (#22420) 2024-10-06 11:33:29 +03:00
kbkpbot
e83b0d221f
x.json2: make encode number cJson compatible (fix #22363) (#22419) 2024-10-06 11:23:42 +03:00
kbkpbot
3c0358cce7
toml: add reflect/decode struct default value support (#22412) 2024-10-06 11:15:04 +03:00
Delyan Angelov
209c30f3a6
v.builder: fix building with -cc msvc and non ASCII characters in paths on windows 11 (#22410) 2024-10-05 02:20:15 +03:00
kbkpbot
dc6a9583d7
v.builder, builtin: use ANSI encoding for the .rsp file under Windows; add builtin string_to_ansi_not_null_terminated + tests (#22409) 2024-10-04 20:29:13 +03:00
Delyan Angelov
5a8ba962a8
v.builder: pass /nologo instead of /NOLOGO, when the user passed -cc msvc on windows 2024-10-04 15:58:29 +03:00
Delyan Angelov
0390c070ec
v.builder: write an UTF8 BOM header for the .rsp file, when using '-cc msvc' (#22408) 2024-10-04 14:00:47 +03:00
yuyi
286c44266d
checker: cleanup in match_expr() (#22407) 2024-10-04 10:11:17 +03:00
Felipe Pena
cafb69dee2
x.json2: add support to array of array (fix #22362) (#22365) 2024-10-04 10:05:05 +03:00
yuyi
884b842930
checker: check fn return void fn call (no value) (fix #22389) (#22404) 2024-10-04 10:01:22 +03:00
Felipe Pena
5b1581daee
cgen: fix global decl type default generation for fixed array (fix #22402) (#22403) 2024-10-03 19:59:57 +03:00
Felipe Pena
1a11056419
checker: fix validation of lambda params and returns in generic function calls (#22387) 2024-10-03 19:56:41 +03:00
yuyi
f24d239199
cgen: improve enum with comptime const value (related #22388) (#22401) 2024-10-03 16:10:19 +03:00
yuyi
985136721e
cgen: fix struct fixed array field init with default value (fix #22392) (#22399) 2024-10-03 11:31:36 +03:00