Skip to content

Emit debug info for generic type aliases. … #29699

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 8, 2020

Conversation

adrian-prantl
Copy link
Contributor

Before comparing the potential sugared type for euqality is needs to be mapped
into the context to resolve generic type parameters to primary archetypes.

rdar://problem/59238327

@adrian-prantl
Copy link
Contributor Author

@swift-ci test

@swift-ci
Copy link
Contributor

swift-ci commented Feb 7, 2020

Build failed
Swift Test Linux Platform
Git Sha - 9d1d652e1ac846329b800f34e6844ae6fe529400

@dcci
Copy link
Member

dcci commented Feb 7, 2020

ugh.

19:10:04 
error: <EXPR>:3:6: error: property 'baciotto' requires the types 'T' and 'Winky' be equivalent
19:10:04 self.baciotto
19:10:04      ^

@swift-ci
Copy link
Contributor

swift-ci commented Feb 7, 2020

Build failed
Swift Test OS X Platform
Git Sha - 9d1d652e1ac846329b800f34e6844ae6fe529400

@adrian-prantl
Copy link
Contributor Author

This is quite interesting. By changing this, we also prefer the decl types of bound generic types, so we end up with types like struct<τ_0_0> instead of struct in the debug info. I think what I really want to do is collect all the type aliases in the decl type and reverse-substitute them in the SIL type.

Before comparing the potential sugared type for equality is needs to be mapped
into the context to resolve generic type parameters to primary archetypes.

<rdar://problem/59238327>
@adrian-prantl
Copy link
Contributor Author

Found a much simpler fix... used the mapped type instead of the decl type.

@adrian-prantl
Copy link
Contributor Author

@swift-ci test and merge

1 similar comment
@adrian-prantl
Copy link
Contributor Author

@swift-ci test and merge

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.

4 participants