dotnet / ClangSharp

Clang bindings for .NET written in C#
MIT License
910 stars 146 forks source link

Latest 18.1.0 release breaks type remapping for args with spaces in them #554

Open kkukshtel opened 4 months ago

kkukshtel commented 4 months ago

As the title says:

Having this line in the rsp:

--remap
__arglist=@params string[] args

Used to work in previous versions by now throws:

Error: Invalid key/value pair argument: string[]. Expected 'name=value'
Error: Invalid key/value pair argument: args. Expected 'name=value'

I was trying to track down the issue and it seems like it's something to do with how the arguments are directly parsed, not the actual logic for extracting them in ParseKeyValuePairs. It seems like maybe context.ParseResult.GetValueForOption maybe splits on spaces so it's resolving multiple arguments instead of a single one?

tannergooding commented 4 months ago

What was the previous version you were on?

There was likely some break or change in System.CommandLine that was missed and we'll need to add a workaround.

kkukshtel commented 4 months ago

I was on 17.0.4. And yeah I agree - I think it has to do with option parsing in System.CommandLine.