Skip to content

Don't crash when asking IsIUO on an incorrectly-SwiftName-d ClangImporter decl. #26726

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
Aug 20, 2019

Conversation

jckarter
Copy link
Contributor

Sometimes the importer creates property decls with nonsensical types in response to nonsensical
SwiftName attributes on Clang types. Don't crash in IsIUORequest when this happens and a property accessor happens to have an unexpected param decl.

…rter decl.

Sometimes the importer creates property decls with nonsensical types in response to nonsensical
SwiftName attributes on Clang types. Don't crash when this happens and a property accessor happens
to have an unexpected param decl.
@jckarter
Copy link
Contributor Author

@swift-ci Please smoke test

@slavapestov
Copy link
Contributor

Can you add a test case?

@jckarter
Copy link
Contributor Author

jckarter commented Aug 20, 2019

I'm not sure it makes sense to, since we should really fix the Clang importer not to build nonsense ASTs like this to begin with, at which point there'd be nothing to reproduce this condition.

@jckarter jckarter merged commit 16fdf88 into swiftlang:master Aug 20, 2019
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