================
@@ -174,7 +191,8 @@ void ElseAfterReturnCheck::registerPPCallbacks(const
SourceManager &SM,
void ElseAfterReturnCheck::registerMatchers(MatchFinder *Finder) {
const auto InterruptsControlFlow = stmt(anyOf(
returnStmt().bind(InterruptingStr), continueStmt().bind(InterruptingStr),
- breakStmt().bind(InterruptingStr),
cxxThrowExpr().bind(InterruptingStr)));
+ breakStmt().bind(InterruptingStr), cxxThrowExpr().bind(InterruptingStr),
+ stmt(isNoReturnStmt()).bind(InterruptingStr)));
----------------
localspook wrote:
I think this could just be written as:
```suggestion
callExpr(callee(functionDecl(isNoReturn()))).bind(InterruptingStr)));
```
with no need for the custom matchers.
https://github.com/llvm/llvm-project/pull/185202
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits