CppSharp icon indicating copy to clipboard operation
CppSharp copied to clipboard

Added support for wchar_t and std::wstring for C#

Open zillemarco opened this issue 8 years ago • 6 comments

With the help of @tritao:

  • added support for wchar_t
  • added support for std::wstring
  • unified the way wide character strings are handled between C# and C++/CLI
  • changed the way strings are handled, using 'IntPtr' instead of 'string' with marshalling attributes on the P/Invokes

zillemarco avatar Oct 12 '17 08:10 zillemarco

Has this been abandoned? Seems like it would be a nice improvement!

phraemer avatar Sep 04 '20 14:09 phraemer

Frankly I have to really apologize for leaving this behind. I had other priorities at work so I couldn't give it the final push it needed.

I think I could be able to get back at this in my free time since not far from now I'll also need this at work. If @tritao or @ddobrev could give me a little refresh on what was missing and/or what should be done I can give it a try. Sorry but it's been almost 3 years and things most likely could have changed that impacted the work I did in this PR too.

zillemarco avatar Sep 04 '20 14:09 zillemarco

I don't recall anymore either, but think it was pretty much good to go.

Please rebase it on top of latest master, make sure all tests still pass and lets take it from there.

tritao avatar Sep 04 '20 15:09 tritao

CLA assistant check
All CLA requirements met.

dnfadmin avatar Sep 05 '20 06:09 dnfadmin

It's not compiling anymore:

Passes\IgnoreSystemDeclarationsPass.cs(60,49): error CS0103: The name 'GetCharSpecializations' does not exist in the current context [C:\projects\cppsharp\src\Generator\CppSharp.Generator.csproj]

Guess some code moved around or was renamed, and needs to be updated in this PR.

tritao avatar Sep 05 '20 10:09 tritao

Yeah I know, during the rebase I had quite a bit of conflicts. I was thinking about drafting the PR until I get it back to work.

zillemarco avatar Sep 05 '20 11:09 zillemarco