================ @@ -1176,6 +1176,10 @@ void Sema::CheckCompletedCoroutineBody(FunctionDecl *FD, Stmt *&Body) { for (AddrLabelExpr *ALE : Fn->AddrLabels) Diag(ALE->getBeginLoc(), diag::err_coro_invalid_addr_of_label); + // Coroutines always return a handle, so they can't be [[noreturn]]. + if (Fn->isCoroutine()) + Diag(FD->getLocation(), diag::warn_noreturn_coroutine) << FD; ---------------- Nerixyz wrote:
Yea, just noticed that I wanted to check if it's noreturn 😅 https://github.com/llvm/llvm-project/pull/127623 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits