Commit Graph

73 Commits (63c9b88e7f3dd10fd4cb762ec9e7dd3be67e650d)

Author SHA1 Message Date
Henrixounez a57e01fee7
parser: dont allow single letter enums (#6526) 2020-10-01 23:29:49 +03:00
Alexander Medvednikov fca344d1fb all: fn args => params 2020-09-27 03:32:56 +02:00
Uwe Krüger 2cb711ee15
checker/channels: check `mut`/`&` state of transmitted objects (#6315) 2020-09-06 21:24:41 +02:00
Uwe Krüger cbcba2e4cf
parser: enable module auto import (of `sync`) (#6271) 2020-08-31 10:44:39 +02:00
Uwe Krüger c351f8fa47
checker, builtin: prepage for builtin channels (#6262) 2020-08-30 08:55:31 +02:00
Daniel Däschle fcc61a981d
all: TypeSymbol.source_name (#6187) 2020-08-22 12:29:15 +02:00
Alexander Medvednikov f965ddae49 parser: handle several errors in types; cgen: objC includes 2020-08-16 19:16:59 +02:00
Uwe Krüger 9602a25a0b
all: add builtin channel type `chan elem_type` (#6126) 2020-08-14 21:18:42 +02:00
Louis Schmieder b58b15993c
gen: compile time for (methods and fields) (#5957) 2020-07-25 00:02:44 +02:00
Enzo 8a855ccae1
fmt,vet: handle `var in [single_value]` (#5882) 2020-07-19 19:58:34 +02:00
Enzo 90d9040e6e
all: make comment expressions + fix vfmt array init (#5851) 2020-07-17 19:13:22 +02:00
Uwe Krüger ef02373061
all: remove `rwshared` keyword, make its semantics default for `shared` (#5710) 2020-07-07 01:57:31 +02:00
KrisChambers 8d035a446a
Fix v/parser: Failure to parse structs with fields typed as anonymous functions returning having an optional void (`?`) return type. (#5684)
* Handle optional void return type in function types in struct fields.

* Add more testing for optional return types in struct fields.

* Move language parsing into it's own function

* Fix issue caused by not setting typ.

* Fix test for structs containing anon fn with optional void return types
2020-07-05 19:29:39 +02:00
Uwe Krüger 3b067f5f85
all: experimental locked concurrency support, part 1 (#5637) 2020-07-04 12:44:25 +02:00
Delyan Angelov 78e1127d99
cgen: treat the main module like any other v module 2020-07-01 00:53:53 +02:00
joe-conigliaro 73da3c9e4c
generic structs: better naming & comments 2020-06-30 09:22:15 +10:00
joe-conigliaro ab37dcaa9c
generic structs: initial implementation 2020-06-29 20:09:09 +02:00
Delyan Angelov b6e6cde3e8 parser: disallow fns with type only args and a body 2020-06-29 10:21:01 +03:00
Adam Stankiewicz b3fc462a78
scanner: fix parsing multiple .amp 2020-06-13 00:01:44 +02:00
Alexander Medvednikov 3bbda7103f Revert "parser: allow void return type for C functions"
This reverts commit d7c63922d5.
2020-06-07 19:06:19 +02:00
Swastik Baranwal d7c63922d5
parser: allow void return type for C functions 2020-06-07 19:45:27 +03:00
Delyan Angelov e534f8507b vlib: minor tweaks for various module imports, needed for vdoc 2020-06-06 19:14:10 +03:00
yuyi 1386c5df13
parser: use `?` instead of `?void` errpr 2020-06-02 17:24:24 +02:00
Alexander Medvednikov 01dbb25a37 checker: do not allow defining methods on types from other modules 2020-05-28 15:23:20 +02:00
Alexander Medvednikov 5423a15f46 generics: more fixes 2020-05-27 15:56:30 +02:00
spaceface777 b10df252dc
all: replace `is_c`, `is_js` with `language` 2020-05-19 17:12:47 +02:00
yuyi 8500c8885c
cgen: fix optional_void error; handle `?` return type 2020-05-15 15:55:03 +02:00
yuyi 6d0b791ac8
parser: warning about unused imports 2020-05-14 17:14:24 +02:00
joe-conigliaro 1b3cd7abe0
cgen: fix sum type assign/push from in match branch & type mod 2020-05-11 16:59:55 +10:00
Ned Palacios 13b11a4155
parser: fix struct attribute for array struct field 2020-05-08 13:09:40 +02:00
yuyi 2f52106253
parser: use .next instead of .check, when a token is already known 2020-05-07 07:51:36 +03:00
Alexander Medvednikov 3ab8dc0092 parser: array init: `[]string` => `[]string{}` 2020-04-26 09:17:17 +02:00
yuyi 541b058e90
all: use `a !in b` instead of `!(a in b)` 2020-04-26 06:39:23 +02:00
joe-conigliaro 6696e1a6e2
table: move set_nr_muls to method 2020-04-25 17:54:32 +10:00
joe-conigliaro fbcdffbbc8
table: move Type functions to methods 2020-04-25 17:08:53 +10:00
Kris Cherven d871595437
all: replace `var` with `mut` 2020-04-23 01:16:58 +02:00
joe-conigliaro abf5942433
parser/cgen: anon fn var & calling (#4534) 2020-04-21 13:23:36 +10:00
Alexander Medvednikov 4b5acfd960 parser: (var x X) receiver syntax 2020-04-16 15:40:21 +02:00
Abdullah Atta 6a186e8f11
jsgen: implement js backend 2020-04-15 23:16:49 +02:00
Alexander Medvednikov da28bc7026 Revert "fmt: `(var f Foo)`"
This reverts commit 4b110756e0.
2020-04-15 04:15:42 +02:00
Alexander Medvednikov 4b110756e0 fmt: `(var f Foo)` 2020-04-15 03:56:16 +02:00
joe-conigliaro c9e290b36f
table: simplify/generalise type fns & remove calls 2020-04-04 16:37:11 +11:00
Alexander Medvednikov 91ffeeb73b parser: fix `(x mut &X)` 2020-04-01 23:56:55 +02:00
Alexander Medvednikov 956bf23390 memory fixes: 21% of V compiler leaks fixed 2020-03-31 14:33:16 +02:00
joe-conigliaro 837bffd03a
parser: parse type - fix multiple & 2020-03-29 01:15:10 +11:00
Joe Conigliaro cf094c6265 cgen: gen fn type declerations 2020-03-16 20:12:03 +11:00
Joe Conigliaro 50ed4004f4 ast/table: use common struct fn decl arguments 2020-03-15 09:21:36 +11:00
Joe Conigliaro a1314bd199 checker/gen/table: impl fn types & sum/other fixes & tidy 2020-03-12 02:10:46 +11:00
Alexander Medvednikov 754a6cc93e cgen: fix -> 2020-03-08 19:38:27 +01:00
Joe Conigliaro f67fca826e v2: fix C function & type prefixing 2020-02-29 21:47:47 +11:00