mirror of
https://github.com/vlang/v.git
synced 2025-09-15 10:27:19 -04:00
pref: fix conflict (#21382)
This commit is contained in:
parent
e4bbd73da3
commit
a1bb84f455
@ -402,7 +402,7 @@ pub fn parse_args_and_show_errors(known_external_commands []string, args []strin
|
|||||||
'-v', '-V', '--version', '-version' {
|
'-v', '-V', '--version', '-version' {
|
||||||
if command_pos == -1 {
|
if command_pos == -1 {
|
||||||
// Version flags after a command are intended for the command, not for V itself.
|
// Version flags after a command are intended for the command, not for V itself.
|
||||||
if current_args.len > 1 && arg == '-v' {
|
if args[i..].len > 1 && arg == '-v' {
|
||||||
// With additional args after the `-v` flag, it toggles verbosity, like Clang.
|
// With additional args after the `-v` flag, it toggles verbosity, like Clang.
|
||||||
// E.g.: `v -v` VS `v -v run examples/hello_world.v`.
|
// E.g.: `v -v` VS `v -v run examples/hello_world.v`.
|
||||||
res.is_verbose = true
|
res.is_verbose = true
|
||||||
|
Loading…
x
Reference in New Issue
Block a user