Skip to content

Commit

Permalink
refactor: Use new style P/Invoke source generation for .Net 7+
Browse files Browse the repository at this point in the history
See: https://learn.microsoft.com/en-us/dotnet/standard/native-interop/pinvoke-source-generation

This is only supported on .Net 7+ and so older versions will still use
the old style `extern` support, which is much more difficult to use with
non-ASCII character sets when interacting with Rust via FFI. This means
that older .Net versions will still not support non-ASCII properly.

New style source generation handles marshalling strings as UTF-8
properly and efficiently so that non-ASCII characters can be used. This
fixes #468.
  • Loading branch information
adamrodger committed Feb 23, 2024
1 parent 09ee818 commit 6e820c9
Show file tree
Hide file tree
Showing 4 changed files with 433 additions and 6 deletions.
Loading

0 comments on commit 6e820c9

Please sign in to comment.