Commit Graph

102 Commits (870ed86afc4023d46ca2433285de20b4c2e5d088)

Author SHA1 Message Date
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
Alexander Medvednikov 59ed4be49a all: update copyright year 2022-01-04 12:21:12 +03:00
pancake 4b55800ffd
v.eval: add tests and fix runtime cast crash (#13019) 2022-01-03 18:30:42 +02:00
Delyan Angelov 6ff953d936
preludes,builder,cgen: add support for VTEST_RUNNER=tap and -test-runner tap (#12523) 2021-12-16 15:59:46 +02:00
Delyan Angelov 3afbb9e90a
all: split all backends into cmd/tools/builders (#12811) 2021-12-12 22:10:43 +03:00
Delyan Angelov 9b7a50b1a2
v: split the interpreter to cmd/tools/vinterpret.v 2021-12-12 00:06:44 +02:00
crthpl 2fbf7fea75
all: initial interpreter code (#12605) 2021-12-08 11:09:10 +03:00
Delyan Angelov 008d15dcb5
builder,pref: add support for `-no-builtin` (useful for writing Linux kernel modules) 2021-10-23 12:53:53 +03:00
czkz da7dad07a3
builder: fix sigint handling for `v run` (#12246) 2021-10-21 16:40:32 +03:00
czkz 3a073329ff
builder: use os.new_process() instead of os.system() in v run (#12214) 2021-10-17 19:01:34 +03:00
Delyan Angelov dee4ffbc99
builder: make -usecache rebuild cached, but changed modules, and their dependants (#12193) 2021-10-15 12:22:59 +03:00
playX 4333a53f28
js: support running `.js.v` tests in `v test-self`, fixes for array methods & codegen (#12011) 2021-09-29 15:33:14 +03:00
yuyi fb75d528eb
builder: remove panics, when cleaning up tmp files after tests (#11525) 2021-09-17 20:56:33 +03:00
playX c175b4fd48
v.gen.js: refactor code, fix alias codegen, `-stats` now again works with tests on the JS backend (#11512) 2021-09-16 14:00:15 +03:00
Ned Palacios aedb6b8e84
v.builder: implement a `-check` mode, that runs only the parser + the checker, without codegen (#11414) 2021-09-07 07:17:53 +03:00
Delyan Angelov d540b3f1a8
v.util: improve formatted_error by adding cached_file2sourcelines, so .split_into_lines is called just once (important for long source files with many errors) 2021-08-14 23:01:30 +03:00
Delyan Angelov 1743ad05c0
v.util: add a small cache for util.read_file, so reading individual source files is done just once 2021-08-14 21:59:28 +03:00
Delyan Angelov 33e4dc3ad3
ci: fix coutput_test.v on windows by fixing `-o -` on windows 2021-08-01 00:27:06 +03:00
Delyan Angelov b0a721b2ec
js: draft support for compiling `-b js x_test.v` 2021-07-27 13:49:47 +03:00
Daniel Däschle ad3835b598
parser: deprecate short struct init (#10842) 2021-07-20 11:17:08 +03:00
playX 425ca5e3c3
v.gen.js: add three backend options for JS, and comptime if support (#10859) 2021-07-19 15:55:03 +03:00
Delyan Angelov 016240d00b
v: support `-o - x_test.v` too, describe `-o -` in the `v help` screen 2021-07-18 16:41:32 +03:00
shadowninja55 0d587d3580
checker: prohibit using non-lvalue as mut receiver (#10790) 2021-07-16 13:03:40 +03:00
Delyan Angelov cbe4ac703e
v.builder: remove temporary file.js file after `v -b js run file.v` 2021-07-16 10:03:46 +03:00
Delyan Angelov 54f6dc70c3
v.util: add Timers.show_remaining/0, use it in v.builder.compile/2 2021-07-06 13:06:11 +03:00
Delyan Angelov 972542d6ee
checker: `[noreturn]` part 2 (cleanup) (#10667) 2021-07-05 05:05:37 +03:00
Delyan Angelov bc01de2181
ast: mark ast.File{} with `[heap]`, and use []&ast.File consistently 2021-05-22 19:06:55 +03:00
Alexander Medvednikov e949d4b26c tools/fast: add "V lines" and "V lines/s" 2021-04-30 15:31:50 +03:00
pancake 6750ed254f x64: rename to `native` to not conflict with the x64 comptime variable 2021-04-27 12:24:58 +03:00
crthpl 903dd49212
v: add support for `$if freestanding {`, without using it (part 1) (#9656) 2021-04-09 23:24:25 +03:00
Delyan Angelov 7c79e9bce7
v.builder: streamline -stats output between backends. add a 'compilation speed' stat too 2021-04-08 12:18:16 +03:00
Larpon b7a0c44f39
builder: allow running symlinked .vsh files (#9385) 2021-03-20 17:25:09 +01:00
Leah Lundqvist 0823ea4af1
builder: produce an iOS binary instead of a bundle (#9316) 2021-03-15 19:03:05 +01:00
Delyan Angelov 69f1e7c9c3
v: fixes for `v -autofree -o v2 cmd/v` 2021-03-14 09:37:38 +02:00
Delyan Angelov d7049ae2da
os: deprecate os.exec (returning ?os.Result), in favour of os.execute, which returns os.Result (#8974) 2021-03-08 20:52:13 +02:00
spaceface b712af56fd
all: bring back `panic(err.msg)` -> `panic(err)` (#9022) 2021-03-01 00:18:14 +01:00
spaceface d63b7bc35a
all: update repo to use the new error handling syntax (#8950) 2021-02-28 23:20:21 +03:00
Delyan Angelov 7f5d654c3a
all: cleanup redundant `.ends_with(_test.v)` calls 2021-01-30 11:08:52 +02:00
Delyan Angelov 760b4c37b9
all: support _test.vv files (to test _test.v errors/checks too) 2021-01-30 10:42:18 +02:00
Lukas Neubert 75d85403a6
fmt: better ternary concat wrapping (#8379) 2021-01-28 11:23:48 +01:00
Delyan Angelov e5a84719ca
all: require calling `optfn() ?` / `optfn() or {...}` for `fn optfn() ? {}` 2021-01-26 16:43:17 +02:00
Lukas Neubert 8b61891348
fmt: smarter if condition wrapping (#8201) 2021-01-23 10:33:22 +02:00
Lukas Neubert ac2c3847af
all: update copyright to 2019-2021 (#8029) 2021-01-18 13:20:06 +01:00
Delyan Angelov 8571d9395b
preludes: move to vlib/v/preludes 2021-01-16 14:43:24 +02:00
Delyan Angelov aa37382e8d
tools: let `v fmt` use VTMP too, stabilise `v test-cleancode` 2021-01-09 20:41:15 +02:00
spaceface 214290d55b
fmt: add a space around single-line `unsafe` expressions (#7505) 2020-12-23 19:13:42 +01:00
Delyan Angelov 4b45f2eaab builder: do not remove executables after run when -keepc is passed; add `-d trace_thirdparty_obj_files` 2020-12-20 12:22:17 +02:00
Delyan Angelov fbf6910ab9
builder: remove executables after `v run file.v` 2020-12-05 13:03:12 +02:00
Delyan Angelov e6116c47be scanner: guarantee an early exit when the parser/scanner is stuck 2020-11-27 12:44:39 +02:00
Alexander Medvednikov 62ee436944 all: remove broken escape sequences after $ in strings 2020-11-27 03:07:37 +01:00