Commit Graph

73 Commits (a3c0a9b7915343bdf69719164df518ed2686a3b5)

Author SHA1 Message Date
yuyi a3c0a9b791
checker: minor optimization in fn_call() and method_call() (#14503) 2022-05-23 08:00:57 +03:00
yuyi 7f03b89611
checker: check method call argument type mismatch (#14496) 2022-05-22 22:16:46 +03:00
yuyi 1f3336c9d3
checker: fix map get anon fn value with mut argument (fix #14479) (#14493) 2022-05-22 16:28:53 +03:00
playX bc397bb0e1
checker: c2v array fix (#14426) 2022-05-17 00:08:41 +03:00
playX 6ec4185017
checker: allow to pass alias to array as a pointer (c2v) (#14389) 2022-05-13 10:17:28 +03:00
Delyan Angelov 8ef9dc6247
ci: run `v fmt -w vlib/v/checker/fn.v` (fix CI regression after 4952967) 2022-05-12 21:24:12 +03:00
playX 4952967366
checker: alias C2V fix (#14377) 2022-05-12 12:19:31 +03:00
yuyi 8f765ed5f1
checker: minor cleanup and speedups in fn_call() (#14343) 2022-05-10 16:41:47 +03:00
yuyi 606d8cfaca
checker: check error for returning aliases of fixed array (#14349) 2022-05-10 14:01:55 +03:00
yuyi 940c78bdfd
checker: minor cleanup in method_call() (#14342) 2022-05-09 18:01:44 +03:00
StunxFS d5e70552eb
checker: check error for `json.decode` (fix #6732) (#14305) 2022-05-08 07:17:11 +03:00
yuyi b04d46770b
ast, checker, cgen: fix error for generic method with generic fn type argument (fix #14239) (#14333) 2022-05-07 20:22:20 +03:00
playX 6a6c005dc0
checker: c2v fixes (#14332) 2022-05-07 09:50:41 +03:00
yuyi 621574c12a
checker: fix error for generic method on nested struct (#14322) 2022-05-07 00:51:04 +03:00
Hunam 0699f324b5
builtin: add `map.values()` (#14301) 2022-05-06 20:42:01 +03:00
yuyi 45fe87c9e3
checker: minor cleanup in fn_call() (#14307) 2022-05-05 21:15:54 +03:00
yuyi b6058bfd6e
parser, checker: fix generic method on nested struct (fix #14089) (#14310) 2022-05-05 11:24:20 +03:00
playX 8afdb1c3ef
checker: c2v: allow passing fixed array as pointer to functions; bool <-> int (#14309) 2022-05-05 11:23:57 +03:00
yuyi 63eacede95
checker: check argument mismatch of array.filter/all/any() (#14273) 2022-05-03 16:56:18 +03:00
Daniel Däschle 08fd0ce0de
all: basic implementation of result type (#14140) 2022-04-30 01:59:14 +03:00
yuyi f89c81087b
checker: check error for array.index() argument (#14147) 2022-04-25 14:42:31 +03:00
yuyi 922cee9162
parser, checker, cgen: fix error for fn call using anon fn call argument (#14155) 2022-04-25 11:26:14 +03:00
yuyi d934472b17
checker: simplify checking array.contains() argument (#14133) 2022-04-22 22:34:13 +03:00
yuyi 99eb9fdaab
checker: fix error for fn with array of aliases argument (#14123) 2022-04-21 12:52:09 +03:00
yuyi f13583b04a
checker: check array builtin method's arguments (#14119) 2022-04-21 12:51:04 +03:00
yuyi 8013bd43b0
checker: check map builtin method's arguments (#14120) 2022-04-21 12:49:46 +03:00
yuyi ce4c2afc9c
checker, cgen: use 'stmts.last()' instead of 'stmts[stmts.len - 1]' (#14105) 2022-04-20 14:23:32 +03:00
yuyi 8cc79e4299
checker: check error for arguments of array.contains() (#14102) 2022-04-20 11:00:59 +03:00
playX f6a0c26a85
checker: c2v fixes (#14091) 2022-04-20 01:09:34 +03:00
JalonSolov daf5d32327
checker: fix error message when number of generic parameters is incorrect (#14090) 2022-04-19 18:34:23 +03:00
yuyi 7ef64bde50
checker: check error for fn decl with optional arguments (#14076) 2022-04-18 21:22:31 +03:00
Delyan Angelov df30b79971
checker: allow for `arr.any(opt_fn()?)`, add test 2022-04-09 19:50:10 +03:00
crthpl b232a3b0d1
cgen: fix `.filter()` and `.map()` on shared arrays (#13954) 2022-04-07 18:05:11 +03:00
StunxFS 725b472d37
checker: fix typos (#13929) 2022-04-04 10:07:53 +03:00
Alexander Medvednikov a55e930c00 checker: fix pointer checks in translated code 2022-04-04 05:35:15 +03:00
Delyan Angelov 44603f8e59
checker: add suggestions for misspelled `mod.func_name()` calls 2022-04-03 20:07:52 +03:00
Vincenzo Palazzo 51c1d666c2
checker: fix operator overloads (for large structs with > 8 fields, the method receiver is normally auto converted to a reference) (#13889) 2022-04-03 19:30:29 +03:00
yuyi bc98c11d9d
parser, checker, cgen: minor cleanup of go_expr() (#13875) 2022-03-31 19:58:04 +03:00
yuyi d40a502981
checker: minor cleanup in fn_call() (#13873) 2022-03-30 21:05:17 +03:00
Delyan Angelov cc637e5ee8
checker: make the misssing shared/mut modifer in fn and method calls error clearer 2022-03-30 01:45:40 +03:00
yuyi c71770d9c5
checker: fix error for array of anon fn call (#13858) 2022-03-29 18:04:30 +03:00
yuyi fd34ebd84e
checker: check the count of generics in fn arguments (#13855) 2022-03-29 10:04:19 +03:00
Vincenzo Palazzo 8b072aa962
checker: check if generic values have the same types (#13718) 2022-03-23 09:13:10 +02:00
yuyi 3e40cd5baa
ast, checker, cgen: fix error for go anon fn variable call (#13776) 2022-03-20 07:45:23 +02:00
Delyan Angelov 7a4715288c
checker: make the errors for call expression shared/mut mismatches more detailed 2022-03-16 22:45:35 +02:00
Alexander Medvednikov 36ec47cd20 all: replace "NB:" with "Note:" (docs/comments) 2022-03-06 20:01:22 +03:00
yuyi b5e7cef1b1
ast: define 'const invalid_type_idx = -1' (#13573) 2022-02-23 11:54:43 +03:00
yuyi 0208e9672d
checker: check array sort_with_compare callback function parameters (#13511) 2022-02-19 10:06:36 +02:00
yuyi f8b8950b96
checker: check mut interface arguments (#13479) 2022-02-16 11:53:41 +02:00
yuyi b5379255da
checker, cgen: fix error for struct embed with fn type (#13450) 2022-02-12 20:55:40 +02:00