Commit Graph

2008 Commits (e6270b05dcf0006867102e7b2a24f0a37a2b27b5)

Author SHA1 Message Date
yuyi e6270b05dc
checker: check unsigned integer compared with negative value (#13670) 2022-03-07 10:26:40 +02:00
Alexander Medvednikov 36ec47cd20 all: replace "NB:" with "Note:" (docs/comments) 2022-03-06 20:01:22 +03:00
yuyi 8136157f87
checker: fix error for 'or expr with nested match expr' (#13658) 2022-03-05 13:06:08 +02:00
yuyi f70e5bd69b
parser: check assign expr with undefined variable (#13653) 2022-03-04 10:33:14 +02:00
yuyi a98eebde7f
checker: add a notice for potentially incorrect smartcasts (#13644) 2022-03-03 16:36:40 +02:00
yuyi ac1b31dbba
checker: fix error for array of interface init in for_in (#13636) 2022-03-03 12:32:55 +02:00
yuyi 288b13b51d
all: cleanup smartcasts in the compiler (#13639) 2022-03-03 10:48:31 +02:00
ChAoS_UnItY 6a3d34ae11
checker: fix #13626, when unwrapped type is fixed array, and selector expr is 'len' (#13627) 2022-03-02 20:46:18 +02:00
yuyi 996bd41ce8
checker: simplify for smartcast in for_stmt() (#13619) 2022-03-01 12:31:48 +02:00
Joe Conigliaro 3b6e122d9d
all: comptime_call - update tmpl scope vars with caller scope vars after their properties got updated in checker 2022-03-01 02:13:29 +11:00
yuyi 0028e557f9
checker: cleanup smartcast in checker.v (#13618) 2022-02-28 17:06:37 +02:00
yuyi 013589e9fe
parser: minor cleanup in global_decl() (#13617) 2022-02-28 13:30:17 +02:00
yuyi efeb3e04da
ast: add table.is_sumtype_or_in_variant() (#13615) 2022-02-28 11:38:20 +03:00
yuyi 81c787ef91
checker: fix match expr with assign sumtype variable (#13614) 2022-02-28 11:37:59 +03:00
yuyi d30ad344e8
checker: check error for array of sumtype appendding (#13593) 2022-02-24 11:07:03 +02:00
yuyi b5e7cef1b1
ast: define 'const invalid_type_idx = -1' (#13573) 2022-02-23 11:54:43 +03:00
yuyi c3ec738126
checker: check struct field reference type mismatch (#13575) 2022-02-23 11:53:22 +03:00
yuyi 6486fffc5a
checker: cleanup `map = {}` processing (#13563) 2022-02-22 16:04:54 +02:00
Larpon 1032cf5c04
checker: only cast as ast.Var if not unresolved, fixes #13561 (#13562) 2022-02-22 15:23:15 +02:00
playX b842e89acc
all: initial implementation of compile-time types (#13549) 2022-02-21 17:42:54 +02:00
eyun 67e33bf9bc
checker: make public the valid_comptime_if_os list (#13518) 2022-02-19 15:22:33 +02:00
yuyi 0208e9672d
checker: check array sort_with_compare callback function parameters (#13511) 2022-02-19 10:06:36 +02:00
yuyi 14073ac0fe
checker: fix error for array of sumtype init (#13501) 2022-02-18 11:47:24 +02:00
Joe Conigliaro f4051e0252
checker: make sure generic struct instantiation uses a known type. closes #13506 2022-02-18 17:54:52 +11:00
Delyan Angelov 245b70cabc
checker: bump iface_level_cutoff_limit to 100 (fix ci) 2022-02-17 11:46:04 +02:00
Delyan Angelov 230dc26858
checker: bump iface_level_cutoff_limit to 99 (fix ci) 2022-02-17 11:42:34 +02:00
Delyan Angelov 901a4d8b84
checker: restrict too deep recursion, to prevent stackoverflows on windows
For v itself, the nesting levels do not exceed 15, so a limit of 40 seems reasonable.
2022-02-17 10:04:11 +02:00
yuyi 842fd7a27e
parser: check assign expr with undefined variables of struct_init (#13495) 2022-02-17 10:21:03 +03:00
Delyan Angelov 89b99ad4c3
scanner: remove the restriction for \x00 in strings (#13493) 2022-02-16 23:41:05 +02:00
yuyi f8b8950b96
checker: check mut interface arguments (#13479) 2022-02-16 11:53:41 +02:00
yuyi f9fc136c24
all: rename InterfaceDecl.ifaces to InterfaceDecl.embeds (#13475) 2022-02-15 11:17:39 +02:00
yuyi b2f984280b
checker: strengthen the judgment of generic type parameters replacement, merge generic type init tests (#13460) 2022-02-14 02:38:47 +02:00
yuyi b5379255da
checker, cgen: fix error for struct embed with fn type (#13450) 2022-02-12 20:55:40 +02:00
Delyan Angelov 799c95dc4e
tests: filter test_ fns with params from the list of automatically run test functions (fix #13443) 2022-02-12 17:30:20 +02:00
yuyi 7178367de0
all: fix error for comptime for in field with generic fn (fix #13409) (#13439) 2022-02-11 22:00:13 +02:00
Tim Basel 9d0a5942ac
builtin: change IError `msg` and `code` to methods + fix vlib, add a deprecation notice for the old usages (#13041) 2022-02-11 15:52:33 +02:00
yuyi a21f4563b3
checker: check the arity and the kinds of the type parameters in generic struct inits (#13429) 2022-02-11 11:21:07 +02:00
Delyan Angelov 9ed18efa53
checker: error on redefining any of the public builtin functions, not just ['print', 'println', 'eprint', 'eprintln', 'isnil', 'panic', 'exit'] (#13419) 2022-02-10 12:26:30 +02:00
yuyi f2eb50008d
parser, checker: cleanup struct short syntax processing (#13416) 2022-02-09 18:31:16 +02:00
yuyi 4be3c92640
checker: check generic struct init without type parameter (#13404) 2022-02-09 14:06:45 +02:00
Vincenzo Palazzo d46ac40758
checker: add error for assigning `none` values (#13383) 2022-02-06 16:08:23 +02:00
div72 cec7e91714
v.parser, v.checker, v.gen: add support for [translated] tag (#13373) 2022-02-06 00:16:02 +02:00
yuyi 173b4652fb
parser: check orm sql statements, using undefined variables in where expr (fix #13367) (#13368) 2022-02-05 11:32:41 +02:00
Vincenzo Palazzo b9fce4ef09
checker: make sure that the operator check is made on the concrete type (#13360) 2022-02-05 00:11:24 +02:00
yuyi a61b4809dc
ast, parser, checker: fix generic struct init with inconsistent generic types (#13359) 2022-02-04 14:24:38 +02:00
Delyan Angelov 85d36ed231
checker: stricter type casting error messages 2022-02-03 14:18:30 +02:00
yuyi b34860e39b
ast, checker: fix error for calling complex nested generic type function (fix #13025) (#13328) 2022-01-31 13:00:27 +02:00
Delyan Angelov 71d98717dc
checker: small cleanup of commit edc6c9e 2022-01-28 11:03:15 +02:00
Yamada Hayao edc6c9e24f
checker: show error instead of panic, when using a `somemodule.NonExistingEnum.enum_value` (#13295) 2022-01-28 11:02:51 +02:00
Delyan Angelov f8f7bc8ead
ci: fix deprecated_module.out file too 2022-01-27 13:16:25 +02:00