Skip to content

[CSApply] Teach adjustSelfTypeForMember about init accessors #71248

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

Merged
merged 1 commit into from
Feb 2, 2024

Conversation

xedin
Copy link
Contributor

@xedin xedin commented Jan 30, 2024

adjustSelfTypeForMember shouldn't load base if member reference is a potential
init accessor use, the proper use of self would be determined during lowering of
the assign_or_init instruction and defensive load for nonmutating sets is unnecessary
in this case.

`adjustSelfTypeForMember` shouldn't load base if member reference
is a potential init accessor use, the proper use of `self` would
be determined during lowering of the `assign_or_init` instruction
and defensive load for `nonmutating` sets is unnecessary in this
case.
@xedin xedin requested a review from hborla as a code owner January 30, 2024 19:11
@xedin
Copy link
Contributor Author

xedin commented Jan 30, 2024

@swift-ci please test

@mansbernhardt
Copy link

Thanks @xedin!
@hborla it would be great if this could be fixed in 5.10 as well.

@xedin xedin merged commit 9d0797a into swiftlang:main Feb 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants