Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/lib/AST/ItaniumMangle.cpp | ||
---|---|---|
1659 | Seems okay to me? ND is the destructor declaration. | |
clang/lib/CodeGen/CGObjCMac.cpp | ||
1806 ↗ | (On Diff #544140) | Yes, if a complex value hit this codepath with a null contBB, it would just crash, so the analysis is flagging a real issue. I'm not sure how to write ObjC code to actually trigger this codepath, though. Probably involves a _Complex _BitInt(128) or something like that. |
clang/lib/AST/ItaniumMangle.cpp | ||
---|---|---|
1659 | Yeah, you're correct -- I was thinking CXXDestructorDecl was not a NamedDecl, but it's a CXXMethodDecl without a name, so this is fine. |
Thank you for the review, @aaron.ballman and @efriedma
Do you recommend any changes here?
The changes to SemaCodeComplete.cpp and ItaniumMangle.cpp are good, the changes in CGObjCMac.cpp require some more work because the static analysis tool found a real bug and we should fix the bug rather than assert it won't be hit. I'd recommend landing the good changes now (they're NFC) and start a new review for the codegen changes.
LGTM! Are you planning to work on the ObjC issues separately? (Not suggesting you have to! But if you don't intend to, can you file an issue in GitHub so we don't lose track of the problem?)
Test failure seems unrelated to change. Driver/fsanitize.c lit test passes in my local testing. Restarting build.
This seems incorrect -- if the declaration name is a destructor, then ND should always be null, right?