You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[6.2][cxx-interop] Fix over-releasing reference members of trival C++ types
Explanation: Large trivial types were copied via memcpy instead of doing a
field-wise copy. This is incorrect for types with reference fields where we also
need to bump the corresponding refcounts. This PR makes sure that trival
C++ types with reference members are not trivial in Swift.
Issues: rdar://160315343
Original PRs: #84321
Risk: There is a low chance of breaking source compatibility as some
types that used to be BitwiseCopyable are no longer considered as such.
However, code relying on that probably has latent memory safety bugs.
Testing: Added a compiler test.
Reviewers: @egorzhdan, @j-hui
0 commit comments