-
Notifications
You must be signed in to change notification settings - Fork 349
[lldb] Increment index of field we're looking for when not an enum #5307
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] Increment index of field we're looking for when not an enum #5307
Conversation
@swift-ci test |
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.
Would be good to comment (I assume it's because enums have exactly 1 field?)
Also: should this be !is_enum &&
field.TR`?
Finally: testcase?
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.
Would be good to comment (I assume it's because enums have exactly 1 field?)
I think the comment there still applies. If it's an enum and there's no typeref then we don't increment the index, because that's a case without a payload.
Also: should this be !is_enum && field.TR`?
I don't think so? If it's not not an enum we always want to increment the index (given the previous comment), in case it's an enum we wan't to increment only if there's a typeref.
Finally: testcase?
If we merge swiftlang/swift#61081 TestSwiftFoundation.py
will catch this. Otherwise I'll have to figure out a way to trigger this behavior.
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.
Ah right.
@swift-ci test |
6845aaa
to
64fe672
Compare
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.
Ah right.
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.
At some point we should write an lldbutil function that calls FileCheck on a text file...
@swift-ci test |
2 similar comments
Targeted branch is |
Oh! So that's why! Thanks @shahmishal! |
2 similar comments
Imported types also don't have typerefs, so we have to increment the index of the field we're looking for in that case.
64fe672
to
3add4d9
Compare
Imported types also don't have typerefs, so we have to increment the index of the field we're looking for in that case.