efriedma-quic wrote: clang already generates certain diagnostics from ExprConstant; expanding the set of diagnostics could be reasonable.
Alternatively, we could try to add some sort of cooperation between DiagRuntimeBehavior and constant evaluation, to try to avoid having to diagnose everything twice: basically, Sema makes a list of constant-evaluated expressions it wants to warn about, then if ExprConstant prints a warning if it sees one of those expressions. https://github.com/llvm/llvm-project/pull/89565 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits