From a1bb84f45594168fae274f8ae49e70a675b10797 Mon Sep 17 00:00:00 2001 From: Turiiya <34311583+ttytm@users.noreply.github.com> Date: Mon, 29 Apr 2024 19:59:57 +0200 Subject: [PATCH] pref: fix conflict (#21382) --- vlib/v/pref/pref.c.v | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vlib/v/pref/pref.c.v b/vlib/v/pref/pref.c.v index 69008a41ae..8152bbb7b9 100644 --- a/vlib/v/pref/pref.c.v +++ b/vlib/v/pref/pref.c.v @@ -402,7 +402,7 @@ pub fn parse_args_and_show_errors(known_external_commands []string, args []strin '-v', '-V', '--version', '-version' { if command_pos == -1 { // 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. // E.g.: `v -v` VS `v -v run examples/hello_world.v`. res.is_verbose = true