-
Notifications
You must be signed in to change notification settings - Fork 479
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DashDash (--) doesn't work properly with multi-value options #605
Comments
After digging into the source, the issue is a loss of context during tokenization. Arguments after the double dash are of type One way to resolve this is to introduce a new token type |
Yes, you are correct. so parsing
will be Value token has a property ExplicitlyAssigned which is true when parser split the option of Edit: |
Hi! I am trying to understand when this is going to be fixed. There is a lot of issues related to it but I understand this as the root issue. The expected behavior of
Where o is an IEnumerable. Thanks |
Hi there, What's the status of this issue? It looks to me that it's recognized as a bug to be fixed? It really bothers me as there is virtually no way to combine |
When using the "DashDash" feature, the results are unexpected when using a multi-valued option.
Single-valued option (base case)
Program.cs
CommandLineOptions.cs
Running the program as follows:
produces the (expected) results:
Multi-valued option (broken case)
CommandLineOptions.cs
Running the program as follows:
produces the (unexpected) results:
Conclusion
My expectation is that any arguments after the
--
would be processed as values, rather than options. Can you confirm my expectations match yours? If so, I'm happy to try to resolve this issue and submit a PR. Thanks!The text was updated successfully, but these errors were encountered: