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

all: require calling optfn() ? / optfn() or {...} for fn optfn() ? {}

This commit is contained in:
Delyan Angelov
2021-01-26 16:43:10 +02:00
parent 97103f680a
commit e5a84719ca
90 changed files with 1994 additions and 1832 deletions

View File

@ -22,7 +22,7 @@ fn test_vexe() {
fn test_can_compile_library() {
os.chdir(cfolder)
os.rm(library_file_name)
os.rm(library_file_name) or { }
res := v_compile('-d no_backtrace -o library -shared library.v')
eprintln('res: $res')
assert os.is_file(library_file_name)
@ -34,7 +34,7 @@ fn test_can_compile_main_program() {
result := v_compile('run use.v')
eprintln('result: $result')
assert result.output.contains('res: 4')
os.rm(library_file_name)
os.rm(library_file_name) or { }
}
fn v_compile(vopts string) os.Result {