[clang] [Clang] skip warnings for constructors marked with the [[noreturn]] attribute (PR #115558)
Oleksandr T. via cfe-commits
cfe-commits at lists.llvm.org
Thu Nov 21 00:26:28 PST 2024
================
@@ -4892,16 +4898,17 @@ CFGBlock *CFGBuilder::VisitCXXFunctionalCastExpr(CXXFunctionalCastExpr *E,
return Visit(E->getSubExpr(), asc);
}
-CFGBlock *CFGBuilder::VisitCXXTemporaryObjectExpr(CXXTemporaryObjectExpr *C,
+CFGBlock *CFGBuilder::VisitCXXTemporaryObjectExpr(CXXTemporaryObjectExpr *E,
AddStmtChoice asc) {
// If the constructor takes objects as arguments by value, we need to properly
// construct these objects. Construction contexts we find here aren't for the
// constructor C, they're for its arguments only.
- findConstructionContextsForArguments(C);
+ findConstructionContextsForArguments(E);
- autoCreateBlock();
- appendConstructor(Block, C);
- return VisitChildren(C);
+ createConstructorBlock(E->getConstructor());
+ appendConstructor(Block, E);
----------------
a-tarasyuk wrote:
@Sirraide Thanks. I've moved these changes to `appendConstructor`
https://github.com/llvm/llvm-project/pull/115558
More information about the cfe-commits
mailing list