Commit Graph

169 Commits (846ddfd728d672ff38d339bb0d1af1e9d374e58a)

Author SHA1 Message Date
Delyan Angelov 410b57b2fa
all: add support for struct field deprecation (#14527) 2022-05-26 00:44:18 +03:00
StunxFS 11bdb04d0c
json: fix struct field default value support (#14304) 2022-05-20 11:22:17 +03:00
Delyan Angelov 668d1b04d2
parser: make script mode errors more informative, when a top level declaration is encountered, after script mode had already started 2022-05-12 21:14:00 +03:00
yuyi d72a25098a
parser: minor cleanup in interface_decl() (#14257) 2022-05-02 16:17:46 +03:00
spaceface 332e821518
checker, gen: add support for a [minify] struct attribute (#14247) 2022-05-02 01:59:17 +03:00
yuyi cd30b6ea82
parser: make sure interface field names use uppercase letters (#14228) 2022-04-30 05:29:33 +03:00
yuyi ec865cfb37
parser: check interface methods name (fix #14217) (#14218) 2022-04-29 15:48:03 +03:00
yuyi 317acfda97
checker: check struct field name using uppercase letters (#14220) 2022-04-29 14:57:14 +03:00
yuyi 93a5d03182
parser: improve embedded struct parsing/better error for `Architecture []string` (#13995) 2022-04-10 10:24:36 +03:00
Vincenzo Palazzo 359f16fdfd
parser: fixed parsing prototype function with recursive type (#13922) 2022-04-05 18:39:49 +03:00
yuyi dd1a8cbadc
parser: check error for struct field type using 'mut' (#13847) 2022-03-28 18:13:38 +03:00
yuyi dd06698ee3
ast: rename TypeSymbol.is_public to TypeSymbol.is_pub (#13710) 2022-03-10 22:18:57 +02:00
yuyi 0fb1eaef04
parser: check the redefinition of built-in IError (#13606) 2022-02-26 09:52:40 +02:00
yuyi f9fc136c24
all: rename InterfaceDecl.ifaces to InterfaceDecl.embeds (#13475) 2022-02-15 11:17:39 +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 10dcb2e0d9
parser: allow embedding interfaces from other modules (#13385) 2022-02-07 00:20:34 +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 a61b4809dc
ast, parser, checker: fix generic struct init with inconsistent generic types (#13359) 2022-02-04 14:24:38 +02:00
yuyi 291a1ffd8d
token: rename Position to Pos, rename position() to pos() (#13279) 2022-01-26 12:36:28 +02:00
yuyi ba3308296b
ast: rename register_type_symbol to register_sym (#13217) 2022-01-19 20:16:23 +02:00
yuyi 155f897270
ast, parser, checker: fix generic struct field with default struct value (#13158) 2022-01-13 22:25:25 +02:00
Alexander Medvednikov 59ed4be49a all: update copyright year 2022-01-04 12:21:12 +03:00
Delyan Angelov 43fee6b3d5
all: fix registration of methods with the same name on different generic structs 2021-12-28 21:42:48 +02:00
yuyi cd0b581445
ast: rename 'table.get_type_symbol()' to 'table.sym()' and more related calls (#12898) 2021-12-19 18:25:18 +02:00
playX 2eb02ff5a7
jsdom, js: start refactoring jsdom; improve JS interfaces; add two attributes for them (#12488) 2021-11-17 11:41:33 +02:00
playX a4c57ba56e
js: support JS interfaces (#12426) 2021-11-11 14:36:32 +02:00
yuyi 8f4180ea09
parser: check generic parameters error of generic struct declaration (#12418) 2021-11-09 09:25:57 +02:00
Delyan Angelov a27833ed0d
all: support `volatile field Type` in struct declarations 2021-11-04 09:45:50 +02:00
yuyi 108a01d65f
fmt: fix unnecessary line break in array init (fix #11448) (#11562) 2021-09-21 16:20:09 +03:00
zakuro 19a43db2de fmt: fix removal of comment before embed in struct (#11384) 2021-09-04 11:02:04 +03:00
Delyan Angelov deb26b92b9
cgen: support `typeof(x).idx`, as well as `iface.type_idx()` (#11178) 2021-08-14 17:22:25 +03:00
zakuro 3979e5c5ff
v.parser: show better position for sort struct init warning (#10939) 2021-07-24 20:41:59 +03:00
Daniel Däschle ad3835b598
parser: deprecate short struct init (#10842) 2021-07-20 11:17:08 +03:00
spaceface 6e942bf4c2
v: initial support for generic interfaces and sumtypes (#10795) 2021-07-15 08:29:13 +03:00
shadowninja55 830cf4645c
v.parser: prohibit registering selectively imported (structs / enums / aliases / interfaces) (#10579) 2021-06-28 10:26:09 +03:00
Delyan Angelov d56ae2d508
v.fmt: keep comments after struct embeds 2021-06-18 18:42:05 +03:00
Delyan Angelov 4b818fa2be
v: implement interface embedding (#9935) 2021-05-02 03:00:47 +03:00
spaceface 7acb48df83
parser: parse `JS.` interfaces properly (#9876) 2021-04-26 09:58:05 +03:00
yuyi dd2002cc57
cgen: fix generics with multi generics struct receiver (#9853) 2021-04-23 15:17:57 +03:00
yuyi 431d806dcf
ast, parser: cleanup of generic structs (#9839) 2021-04-22 18:21:01 +03:00
Lukas Neubert 2df260acbb
parser: fix last_line of no body C struct (#9809) 2021-04-20 21:37:00 +03:00
spaceface 73352583e7
ci: fix all `-cstrict` warnings with gcc and clang (#9792) 2021-04-19 15:38:48 +03:00
Ned Palacios 6948419595
parser: fix InterfaceDecl's position (#9649) 2021-04-09 17:18:22 +02:00
Lukas Neubert a0648a3ec2
all: fixes related to Node.pos (#9613) 2021-04-06 15:16:19 +02:00
Ned Palacios 07b1dc66dd
ast, parser: add additional pos info for FnDecl and InterfaceDecl nodes (#9603) 2021-04-05 18:14:21 +03:00
Ned Palacios 1bb48c3577
ast, parser: patches for VLS (#9562) 2021-04-02 16:26:37 +02:00
Alexander Medvednikov 7385f8e56b all: a massive merge of ast and table modules 2021-04-02 01:57:09 +03:00
Alexander Medvednikov 6f318be96c checker: do not allow nil sum types init 2021-03-31 11:13:52 +03:00