[clang] Don't wrap immediate invocations in ConstantExprs within constexpr initializers (PR #89565)

Daniel M. Katz via cfe-commits cfe-commits at lists.llvm.org
Mon Apr 22 10:34:35 PDT 2024


https://github.com/katzdm commented:

@cor3ntin Thanks for your review; this is ready for another look.

Note that the use of a full `ExpressionEvaluationContext` caused a handful of other tests to start failing - in particular, ones that previously expected warnings related to changes of value from implicit casts. I verified that these warnings are all emitted through `Sema::DiagRuntimeBehavior`, which no-ops when in a `ConstantEvaluated` context - so the lack of warning seems expected since the initializer is now treated as a constant expression.

https://github.com/llvm/llvm-project/pull/89565


More information about the cfe-commits mailing list