-
Notifications
You must be signed in to change notification settings - Fork 344
[lldb] Implement TypeSystemSwiftTypeRef::IsMeaninglessWithoutDynamicResolution #2191
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
[lldb] Implement TypeSystemSwiftTypeRef::IsMeaninglessWithoutDynamicResolution #2191
Conversation
Running the tests results in one
It seems something about this tree pattern will need to be special cased. |
I had a new thought, maybe this is a bug and the existing implementation is incorrect? Should |
This is a generic type, so naively one would think it is dynamic. However, since it is a function type, we don't actually have any means to bind it like we do for other types, since it the binding would only happen at one specific call site. I think it would be most intuitive if both implementations returned false. Probably by special-casing function types. |
Sounds reasonable.
Do you have any thoughts on how to narrow which function types? There are a number of node kinds named with "
|
I would just defer this question to TypeSystem::IsFunctionType() and worry about whether it is implemented correctly when/if that becomes a problem. |
I see a |
auto *node = DemangleCanonicalType(dem, type); | ||
if (IsFunctionType(type, nullptr)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note that this will demangle the type twice.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's ok, we will do an NFC performance pass once the implementation is complete. For now let's focus on clarity!
@swift-ci test |
@swift-ci test |
@swift-ci test |
Implement
TypeSystemSwiftTypeRef::IsMeaninglessWithoutDynamicResolution
.rdar://68171389