Skip to content

[6.2][IRGen] Fix placeholder logic for emission of conditionally inverted protocols #82352

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

Open
wants to merge 1 commit into
base: release/6.2
Choose a base branch
from

Conversation

drexin
Copy link
Contributor

@drexin drexin commented Jun 18, 2025

  • Explanation: Instead of counting the actual conformances, the logic took the size of the bit field, i.e. used the highest set bit, so when a type had a conditional conformance only on ~Escapable, but not on ~Copyable, it would still add 2 placeholders, but only fill one.
  • Scope: Metadata emission for types with conditional conformance on inverted protocols
  • Issues: rdar://153681688
  • Original PRs: [IRGen] Fix placeholder logic for emission of conditionally inverted … #82347
  • Risk: Low. Issue is affecting a very specific case and the fix is tested.
  • Testing: Added validation test that observes the issue before the fix and not after.
  • Reviewers: @meg-gupta

…protocols

rdar://153681688

Instead fo counting the actual conformances, the logic took the size of the bit field, i.e. used the highest set bit, so when a type had a conditional conformance only on ~Escapable, but not on ~Copyable, it would still add 2 placeholders, but only fill one.
@drexin drexin requested a review from a team as a code owner June 18, 2025 21:53
@drexin drexin added 🍒 release cherry pick Flag: Release branch cherry picks swift 6.2 labels Jun 18, 2025
@drexin
Copy link
Contributor Author

drexin commented Jun 18, 2025

@swift-ci test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🍒 release cherry pick Flag: Release branch cherry picks swift 6.2
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant