-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Ensure we cleanup the marshalling for elements of collections (stateful and stateless) #76629
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
Conversation
…ul and stateless)
Tagging subscribers to this area: @dotnet/interop-contrib Issue DetailsWe accidentally lost the element marshalling when moving to the released marshaller design. This PR adds it back with matching logic to the previous marshaller design. Verified manually that we emit the right code for the case in #76584 Fixes #76584 Given the scope of the break that this fixes (memory leaks), I think this is a backport candidate.
|
What do you think about adding tests that just validate the |
I'll try to come up with a test. |
Yes, it is. |
...opServices/gen/Microsoft.Interop.SourceGeneration/Marshalling/StatefulMarshallingStrategy.cs
Show resolved
Hide resolved
...me.InteropServices/gen/Microsoft.Interop.SourceGeneration/Marshalling/ElementsMarshalling.cs
Outdated
Show resolved
Hide resolved
src/libraries/System.Runtime.InteropServices/tests/TestAssets/SharedTypes/NonBlittable.cs
Outdated
Show resolved
Hide resolved
/backport to release/7.0 |
Started backporting to release/7.0: https://github.com/dotnet/runtime/actions/runs/3193476808 |
We accidentally lost the element marshalling when moving to the released marshaller design. This PR adds it back with matching logic to the previous marshaller design.
Verified manually that we emit the right code for the case in #76584
Fixes #76584
Given the scope of the break that this fixes (memory leaks), I think this is a backport candidate.