Bug 1499288: [100% Repro] [Bedrock_Windows_CI] [win32_x86 --unity --p…ch] Tests "Minecraft.UnitTest.Runner" and "Vanilla.SharedTests.UnitTest.Runner" are failing in run tests step #11
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix crash in mocked destructors in x86. Destructor mocks use union_cast to cast a member pointer to a void*. When the mock is to be called, those are pulled back out and cast to a non-member function that takes the class. Due to luck and calling convention, this happens to work, but stopped now on x86. Fix the issue by union_casting the object back to the member function it original was rather than a different non-member function. Additionally, apply the previous xcode fix to the headers so running the generation script doesn't erase it: 6b685cb
This is a simplified version of the type of casting it was doing, which works on x64 but crashes now on x86.