Delyan Angelov
6134c4870b
v.util: extract v.util.version, use it to speed up building v repl, v up and v doctor
2021-07-27 12:59:56 +03:00
Delyan Angelov
5098334e65
os: add execute_or_exit(cmd), use it consistently instead of execute_or_panic(cmd)
2021-07-20 15:22:04 +03:00
Daniel Däschle
ad3835b598
parser: deprecate short struct init ( #10842 )
2021-07-20 11:17:08 +03:00
William Gooch
51dd8304bb
tools: make the v REPL help screen look nicer ( #10833 )
2021-07-17 11:23:29 +03:00
shadowninja55
0d587d3580
checker: prohibit using non-lvalue as mut receiver ( #10790 )
2021-07-16 13:03:40 +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
6aecda3be8
all: support [noreturn] fn abc() { for{} }, mark panic/1 and exit/1with it too. ( #10654 )
2021-07-04 20:24:19 +03:00
Delyan Angelov
b6bd6d1d35
tests: add cmd/tools/vdoc/tests/vdoc_file_test.v, extract a v.util.diff module, cleanup
2021-06-22 18:52:34 +03:00
Delyan Angelov
79df7f51c3
v: deprecate [if ident] in favour of [if ident ?]
2021-06-22 10:30:14 +03:00
Delyan Angelov
71523c86a1
v.util: simplify smart_quote more
2021-06-21 16:08:19 +03:00
Delyan Angelov
45c6b6493b
v.util: make util.smart_quote use its output string builder directly
2021-06-21 09:13:38 +03:00
Yuriy Zymlex
a716a00e38
builder: fix a bug with submodule import ( #10318 )
2021-06-05 12:45:23 +03:00
R cqls
5b8402bccb
parser: fix mod_path_to_full_name to be compliant with --path option ( #10149 )
2021-05-25 07:46:40 +03:00
Enzo
886f69bfcf
all: use operator overloading on strings (p. 2) ( #10183 )
2021-05-24 11:38:31 +03:00
Enzo
906b207e58
checker: deprecate using V strings in C function calls ( #10140 )
2021-05-20 09:17:44 +03:00
Delyan Angelov
ac469f5eff
v.depgraph: fix detection of indirect module dependency cycles
2021-05-20 01:53:41 +03:00
Delyan Angelov
159ee00563
builtin: remove import hash
2021-05-10 09:22:50 +03:00
Delyan Angelov
84f9789e72
v: tag more low level functions with [direct_array_access]
2021-05-06 00:35:16 +03:00
Delyan Angelov
597a774d36
scanner: speed up Scanner.skip_whitespace (~2-3% speed up of -o x.c cmd/v)
2021-05-03 14:14:32 +03:00
Delyan Angelov
d4f31412b7
v: deprecate @VROOT in favour of @VMODROOT ( #9795 )
2021-04-19 19:01:47 +03:00
Delyan Angelov
c1f2c570bc
v.util: prevent diff tool lookups when VDIFF_TOOL is set
2021-04-06 13:22:04 +03:00
Delyan Angelov
19b915b105
ci: fix windows-tcc job
2021-04-05 23:35:22 +03:00
Delyan Angelov
10619d098c
ci: fix a race in vlib/v/compiler_errors_test.v execution on m1
2021-04-05 22:57:59 +03:00
Alexander Medvednikov
57e6138a61
all: remove byteptr and charptr; replace them with &byte and &char
2021-04-04 17:43:32 +03:00
Delyan Angelov
c698fa1a58
all: support v -watch run ( #9577 )
2021-04-04 16:05:06 +02:00
Delyan Angelov
9b78d7d21d
tools: check formatting of more modules with v test-cleancode, colorize v vet output
2021-03-24 12:39:39 +02:00
Alexander Medvednikov
0c055a1ce9
all: s.contains(s2) instead of in
2021-03-23 11:38:56 +03:00
Ned Palacios
aa4e22c287
scanner, token: add column information to tokens ( #9407 )
2021-03-23 06:23:46 +01:00
Delyan Angelov
a00c80b98f
v: support compiler notices. Use them for [deprecated_after: '2021-05-01'] tags
...
Compiler notices are like warnings, with these differences:
a) notices use a different color.
b) notices use a different label.
c) notices do not prevent compilation with -prod.
(warnings are converted to errors with -prod)
2021-03-22 19:59:00 +02:00
Lukas Neubert
a67d49050c
math: add a pure V math.mathutil, with generic min, max and abs functions ( #9176 ), and use it consistently
2021-03-12 11:28:04 +02:00
Joe Conigliaro
fd2845e955
v.util: change naming behaviour for modules relative to working dir. closes #9138
2021-03-10 16:28:06 +11:00
zakuro
00399b49ab
v.util: add util.tabs() ( #9211 )
2021-03-09 13:03:25 +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
pancake
ed9ca0b7bd
build: add address sanitizer make target ( #9044 )
2021-03-07 16:44:54 +01:00
zakuro
45d51c76da
v.util: add an iabs(x) helper ( #9172 )
2021-03-07 11:24:05 +02:00
spaceface
b712af56fd
all: bring back panic(err.msg) -> panic(err) ( #9022 )
2021-03-01 00:18:14 +01:00
zakuro
ce115dcbe0
builtin: correct error underline for unicode wide chars ( #9010 )
2021-03-01 00:18:02 +01:00
spaceface
d63b7bc35a
all: update repo to use the new error handling syntax ( #8950 )
2021-02-28 23:20:21 +03:00
Alexander Medvednikov
3a2d696fac
time: time.wait() => time.sleep()
2021-02-27 20:41:06 +03:00
Nick Treleaven
c03798e390
checker: disallow implicit conversion from fixed array to fooptr ( #8823 )
2021-02-26 00:28:47 +01:00
Delyan Angelov
1c0eefae38
parser/scanner: replace p.peek_tok2/3 with p.peek_token(2/3) ( #8946 )
2021-02-24 21:03:53 +03:00
zakuro
f54c1a5cc2
all: add strings.Builder.write_string and use write_string instead of write ( #8892 )
2021-02-22 13:18:11 +02:00
zakuro
ac4791045f
time: consolidate the different sleep functions into time.wait(Duration) ( #8853 )
2021-02-21 17:05:03 +02:00
Swastik Baranwal
ad162cd6fc
checker: stricter unknown type checks, show better suggestions ( #8816 )
2021-02-19 11:23:13 +02:00
Nick Treleaven
4ccf991f61
checker: warn when casting a fixed array (use &arr[0] instead) ( #8787 )
2021-02-17 20:45:11 +01:00
Nick Treleaven
4a0367a63c
vlib: add [unsafe] tag to more functions: tos, string_from_wide, strings.Builder: write_bytes, free ( #8766 )
2021-02-15 17:15:52 +02:00
Uwe Krüger
374739b804
all: rename [ref_only] -> [heap] ( #8718 )
2021-02-13 16:52:01 +02:00
Nick Treleaven
9e751f72c4
doc, fmt: use map{key: value} syntax for map literals ( #8623 )
2021-02-08 16:57:42 +02:00
Lukas Neubert
473cd1d416
fmt: single line ternary return ( #8605 )
2021-02-08 00:28:46 +01:00
Delyan Angelov
16dffc7c1d
compiler: move timing_start/timing_measure to util.timing_start/util.timing_measure
2021-02-05 16:34:56 +02:00