fix compiler_test.v
parent
914e9df6ba
commit
fd12e4e826
24
cmd/v/v.v
24
cmd/v/v.v
|
@ -5,7 +5,6 @@ module main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
internal.compile
|
internal.compile
|
||||||
internal.flag
|
|
||||||
internal.help
|
internal.help
|
||||||
os
|
os
|
||||||
os.cmdline
|
os.cmdline
|
||||||
|
@ -41,22 +40,14 @@ fn main() {
|
||||||
}
|
}
|
||||||
prefs2, command := parse_args(args)
|
prefs2, command := parse_args(args)
|
||||||
//println('command = $command')
|
//println('command = $command')
|
||||||
//command := if values.len > 0 { values[0] } else { '' }
|
|
||||||
/*
|
|
||||||
prefs := flag.MainCmdPreferences{}
|
|
||||||
values := flag.parse_main_cmd(os.args, parse_flags, prefs) or {
|
|
||||||
println('V Error: An error has occurred while parsing flags: ')
|
|
||||||
println(err)
|
|
||||||
exit(1)
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
if prefs2.is_verbose {
|
if prefs2.is_verbose {
|
||||||
println(util.full_v_version())
|
println(util.full_v_version())
|
||||||
}
|
}
|
||||||
if prefs2.is_verbose {
|
if prefs2.is_verbose {
|
||||||
//println('Parsed preferences: ')
|
//println('args= ')
|
||||||
|
//println(args) // QTODO
|
||||||
|
//println('prefs= ')
|
||||||
//println(prefs) // QTODO
|
//println(prefs) // QTODO
|
||||||
//println('Remaining: $values')
|
|
||||||
}
|
}
|
||||||
// Start calling the correct functions/external tools
|
// Start calling the correct functions/external tools
|
||||||
// Note for future contributors: Please add new subcommands in the `match` block below.
|
// Note for future contributors: Please add new subcommands in the `match` block below.
|
||||||
|
@ -155,15 +146,6 @@ fn invoke_help_and_exit(remaining []string) {
|
||||||
exit(1)
|
exit(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
[inline]
|
|
||||||
fn disallow_unknown_flags(prefs flag.MainCmdPreferences) {
|
|
||||||
if prefs.unknown_flag == '' {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
println('V Error: Unexpected flag found: $prefs.unknown_flag')
|
|
||||||
exit(1)
|
|
||||||
}
|
|
||||||
|
|
||||||
fn create_symlink() {
|
fn create_symlink() {
|
||||||
$if windows {
|
$if windows {
|
||||||
return
|
return
|
||||||
|
|
|
@ -26,7 +26,7 @@ fn test_all() {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
os.rm('exe')
|
os.rm('exe')
|
||||||
x := os.exec('$vexe -o exe -cflags "-w" -cg -backend experimental $program') or {
|
x := os.exec('$vexe -o exe -cflags "-w" -cg $program') or {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
// os.rm(program)
|
// os.rm(program)
|
||||||
|
|
Loading…
Reference in New Issue