================ @@ -60,6 +61,45 @@ static bool isTrivialDoWhile(const CFGBlock *B, const Stmt *S) { return false; } +// Check if the block starts with a coroutine statement and see if the given +// unreachable 'S' is the substmt of the coroutine statement. +// +// We suppress the unreachable warning for cases where an unreachable code is +// a substmt of the coroutine statement, becase removing it will change the +// function semantic if this is the only coroutine statement of the coroutine. +static bool isInCoroutineStmt(const CFGBlock *Block, const Stmt* S) { ---------------- usx95 wrote:
nit: rename `S` to `Unreachable` to avoid confusion with other variables named `S`. https://github.com/llvm/llvm-project/pull/77454 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits