| ... | @@ -799,9 +799,9 @@ fn buildOutputType( | ... | @@ -799,9 +799,9 @@ fn buildOutputType( |
| 799 | return cleanExit(); | 799 | return cleanExit(); |
| 800 | } else if (mem.eql(u8, arg, "--")) { | 800 | } else if (mem.eql(u8, arg, "--")) { |
| 801 | if (arg_mode == .run) { | 801 | if (arg_mode == .run) { |
| 802 | // The index refers to all_args so skip `zig` `run` | 802 | // args_iter.i is 1, referring the next arg after "--" in ["--", ...] |
| 803 | // and `--` | 803 | // Add +2 to the index so it is relative to all_args |
| 804 | runtime_args_start = args_iter.i + 3; | 804 | runtime_args_start = args_iter.i + 2; |
| 805 | break :args_loop; | 805 | break :args_loop; |
| 806 | } else { | 806 | } else { |
| 807 | fatal("unexpected end-of-parameter mark: --", .{}); | 807 | fatal("unexpected end-of-parameter mark: --", .{}); |