-
Notifications
You must be signed in to change notification settings - Fork 847
Open
Description
Consider script test_args.fsx:
printfn "%A" fsi.CommandLineArgs
When execing:
>dotnet fsi test_args.fsx -r -f
[|"test_args.fsx"; "-r:-f"|]
When using:
>dotnet fsi --use:test_args.fsx -- -- -r -f
Microsoft (R) F# Interactive version 14.0.101.0 for F# 10.0
Copyright (c) Microsoft Corporation. All Rights Reserved.
For help type #help;;
> [|"test_args.fsx"; "-r:-f"|]
val it: unit = ()
From looking over fsi.fs, it seems that PostProcessCompilerArgs is called before any other command line processing. This will find the '-r' and treat it as an abbreviated --reference option, combining it with its "argument" into a single -r:-f. Perhaps, rather than the initial PostProcessCompilerArgs, the check for a space-separated arg for -r (for example) could be added to the main loop in ParseCompilerOptions.
Metadata
Metadata
Assignees
Type
Projects
Status
New