https://github.com/Sirraide requested changes to this pull request.

Yeah, I agree we should be warning on this.

However, AnalysisBasedWarnings isn’t really the right place for this, because 
that’s all about emitting warnings based on control-flow analysis, but whether 
a function is a coroutine or declared noreturn is known even without 
control-flow analysis, so this should probably go somewhere else (additionally, 
the analysis-based warnings pass doesn’t run if there are *any* errors anywhere 
else in the TU—another reason why handling this elsewhere would be 
preferrable). Probably where we create the FunctionDecl?

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

Reply via email to