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
When processing thunk functions and elementtypes with
inheritance, there were logic errors in the direct base checking
that could lead to incorrect function types being retained.
The issue occurred in the following case:
1. Initial comparison: CurrentThisStructTy (ios_base) == NewThisTy (ios_base)
- Both types are the same, so NewIsDirectBase is incorrectly set to true
- ThunkFn type: void (%class._ZSt8ios_base*)
- ThunkFnTy: (%class._ZSt8ios_base*)
- Since types match, no update occurs
2. Second comparison: CurrentThisStructTy != NewThisTy
- ThunkFn then gets updated to void (%class._ZSt9basic_iosIcSt11char_traitsIcEE*)
- This is correct behavior
3. Third comparison: Same types again (ios_base == ios_base)
- NewIsDirectBase is again set to true, which will then affect updating the ThunkFn
- Current ThunkFn: void (%class._ZSt9basic_iosIcSt11char_traitsIcEE*)
but the one we want to update to is void (%class._ZSt8ios_base*)
- Because NewIsDirectBase is true, the update is skipped eventhough
ThunkFn != ThunkFnTy. This leaves ThunkFn with the wrong type
0 commit comments