Closed hackwaly closed 5 days ago
Operating System: macOS
moon 0.1.20241115 (67c2b06 2024-11-15) ~/.moon/bin/moon moonc v0.1.20241115+351cfb074 ~/.moon/bin/moonc moonrun 0.1.20241115 (67c2b06 2024-11-15) ~/.moon/bin/moonrun
moon run ./src/main -- -o a.out a
// main.mbt fn main { let usage = #|Usage: moonyacc [options] <input-file> let output_file = @ref.new("") let input_file = @ref.new("") @ArgParser.parse( [("--out-file", "-o", Set_string(output_file), "Output file")], fn(rest) { input_file.val = rest }, usage, @sys.get_cli_args(), ) println("Input file: \{input_file}") println("Output file: \{output_file}") }
error: unexpected argument '-o' found tip: to pass '-o' as a value, use '-- -o' Usage: moonrun [OPTIONS] <PATH> [ARGS]... For more information, try '--help'. error: failed to run
Bug Report
Environment
OS
Operating System: macOS
MoonBit CLI Tools Version
Steps to Reproduce
Expected Behavior
Actual Behavior
Checklist