Skip to content

Implement TypeSystemSwiftTypeRef::GetReferentType() #2267

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
Dec 19, 2020

Conversation

adrian-prantl
Copy link

rdar://68171397

@adrian-prantl
Copy link
Author

@swift-ci test

Comment on lines +2526 to +2527
(node->getKind() != Node::Kind::Unowned &&
node->getKind() != Node::Kind::Unmanaged) ||

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this handle Weak too?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, there's a separate function for it?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That surprised me too and frankly I think this API is questionable, but the SwiftASTContext implementation specifically excludes weak references!

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The other function in SwiftLanguageRuntime also unravels the Optional type that is expected in a weak reference.

@adrian-prantl adrian-prantl merged commit ae2e3d9 into swift/release/5.4 Dec 19, 2020
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.

2 participants