1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00
Commit Graph

738 Commits

Author SHA1 Message Date
Felipe Pena
029e8a815b
checker: fix type checker on auto deref var (#18842) 2023-07-13 11:56:11 +03:00
yuyi
7f8749afdd
checker: change 'expr(expr_ ast.Expr)' to 'expr(mut expr ast.Expr)' (#18781) 2023-07-05 17:02:22 +03:00
yuyi
c1550b3efa
ast, checker: change stmt(node_ ast.Stmt) to stmt(mut node ast.Stmt) (#18756) 2023-07-03 23:10:00 +03:00
yuyi
44a6741bc3
ast, checker: change check(ast.file &ast.File) to check(mut ast.file ast.File) (#18729) 2023-07-02 09:41:04 +03:00
Alexander Medvednikov
a9f8b5dadc all: static type methods 2023-06-27 01:23:30 +03:00
yuyi
22bd1b9d55
ast: clean up ast.StructInit (#18518) 2023-06-22 16:41:08 +03:00
Turiiya
396d46d9ca
ast, builder, checker, parser: fix typos (#18480) 2023-06-18 22:36:17 +03:00
yuyi
acfe785597
all: clean up with is_any_kind_of_pointer() (#18467) 2023-06-17 14:10:06 +03:00
yuyi
dd1d5bca1b
ast: clean up ast.StructInit (#18387) 2023-06-09 17:43:21 +03:00
Felipe Pena
8d2a0ffe37
cgen: fix option handling with auto heap variable (#18336) 2023-06-04 18:10:22 +02:00
Alexander Medvednikov
45f16a2640 all: coroutines (part 1) 2023-05-27 23:33:46 +02:00
Felipe Pena
38a155ac81
cgen: make comptime call works with or-block (#18215) 2023-05-21 15:22:40 +02:00
yuyi
2bb24ee739
fmt: implement comments inside sumtype declaration (#18189) 2023-05-18 11:22:26 +02:00
Felipe Pena
47761a42e9
all: attr for enum fields (+ json encode/decode) (#18163) 2023-05-13 01:08:30 +02:00
Felipe Pena
1e56a69c02
checker, parser: save shared/atomic specifier for ast.Param (#18124) 2023-05-09 00:22:22 +03:00
yuyi
a0a8b7e47a
ast, parser, checker, cgen, fmt: implement generic fn params (fix #14937) (#18126) 2023-05-07 19:53:56 +02:00
Felipe Pena
377c2e25ff
all: allow recursive struct with option ptr (?&Node) (#17682) 2023-04-18 13:07:21 +02:00
yuyi
a938dcddb5
ast: minor cleanup in ast.v (#17962) 2023-04-15 14:29:15 +03:00
Felipe Pena
6a60db8768
cgen, checker: fix generic/comptime parameter concrete type resolution in some cases (#17762) 2023-04-10 10:42:49 +03:00
Felipe Pena
063f4023c5
checker: allow mut var.$(field.name) (#17911) 2023-04-10 10:37:02 +03:00
yuyi
e70084f203
ast: clean up ast.v, table.v and types.v (#17906) 2023-04-07 16:58:34 +03:00
Delyan Angelov
dce65c7f46
tools: make v watch webserver.v monitor files used through $tmpl as well 2023-04-06 00:45:25 +03:00
walking devel
8452644ec3
orm: enforce that queries always return a Result, a query-resulting array can be used as a V array in place. (#17871) 2023-04-04 08:23:06 +03:00
yuyi
e1b8617c94
ast, cgen: fix generic closures with different generic types (fix #17829) (#17834) 2023-03-31 18:08:42 +03:00
yuyi
b9352ce834
ast, parser, fmt: fix fmt error of generic fntype (#17814) 2023-03-30 13:30:10 +02:00
Alexander Medvednikov
6756d28595 all: 2023 copyright 2023-03-28 22:55:57 +02:00
Felipe Pena
9a9cfe425c
all: comptime type lowercase ($int, $enum, $option, etc) (#17732) 2023-03-23 00:02:42 +01:00
Felipe Pena
b71c131678
cgen: fix map with comp-time reflection, improve comptime var handling (#17603) 2023-03-14 13:49:29 +02:00
Felipe Pena
3197ec1a41
v: add compile-time enum evaluation with $for item in MyEnum.fields { dump(item.value) dump(item.name) } (#17517) 2023-03-12 12:46:54 +02:00
yuyi
95a9f0e29b
ast, parser, fmt: fix fmt error of infix expr with comments (fix #17560) (#17583) 2023-03-12 01:07:13 +02:00
Felipe Pena
ee4150f213
v: add a $Option comp-time type, to enable: $for f in Test.fields { $if f.typ is $Option { } } (#17546) 2023-03-10 12:17:25 +02:00
ChAoS_UnItY
ae6a48c0e3
all: rename it to index in array inits (#17543) 2023-03-08 20:51:45 +01:00
l-m
0625caad56
wasm: add a webassembly compiler backend, based on using binaryen (#17368) 2023-02-28 23:58:53 +02:00
Felipe Pena
2879c5110c
cgen, check, parser: implement first-class option type (#17017) 2023-02-18 11:45:01 +02:00
yuyi
e76e93d230
ast: add comments for ast.AssertStmt and ast.IfGuardExpr (#17235) 2023-02-06 16:39:03 +02:00
walking devel
a489417484
orm: detect type mismatching on inserting an object (#17157) 2023-01-30 11:26:10 +02:00
l-m
bb512f782e
checker, ast: add field promoted_type for InfixExpr, filled in by the checker, to save duplicate work in the backends (#17158) 2023-01-29 21:06:05 +02:00
l-m
c14d15bd3d
ast,checker,parser,cgen: [c:'sym'] rework; allow compiling code from .v files tagged with [translated] without needing -translated too (#17125) 2023-01-26 17:47:38 +02:00
Swastik Baranwal
e32ed368ca
ast, checker, parser: add enum type pos (#17112) 2023-01-25 21:59:28 +02:00
Delyan Angelov
1cad788779
checker: add error for type Alias = map[string]Alias (fix #17008) (#17015) 2023-01-18 01:34:43 +02:00
yuyi
64558df764
vlib: move the mysql/sqlite/pg/mssql modules under vlib/db (#16820) 2023-01-13 17:02:32 +02:00
Delyan Angelov
1582db1a0a
comptime: add support for T is $Alias and T is $Function (#16929) 2023-01-10 08:49:04 +02:00
JalonSolov
90941b3b1f
all: change optional to option (#16914) 2023-01-09 09:36:45 +03:00
Delyan Angelov
43d8bc30f9
checker: fix unset type of a pointer field with default value, when a struct contains an embed (fix #16882) (#16883) 2023-01-05 19:53:37 +02:00
Swastik Baranwal
09766c44b6
checker: disallow struct{...val.$(field.name)} (#16852) 2023-01-03 10:21:32 +02:00
Felipe Pena
9b28a7aa96
checker,cgen: fix comptime value recognition on generic arguments (#16768) 2022-12-26 18:44:18 +02:00
Delyan Angelov
0a11955284
parser: support an unambiguous sizeof[T]() and isreftype[T]() (part 1) (#16684) 2022-12-15 19:21:52 +02:00
Delyan Angelov
48a7de643e
all: support typeof[ T ]().idx and typeof[ T ]().name, where T can be any type, including ![]&string (#16513) 2022-12-07 11:26:27 +02:00
Swastik Baranwal
a9b41d2980
all: add support for const ident in match range (#16526) 2022-11-26 08:56:00 +02:00
Hitalo Souza
45854882b9
builtin, cgen: support FieldData.unaliased_typ, use it for generalising x.json2 (able to encode type aliased struct fields) (#16469) 2022-11-20 11:18:14 +02:00