[all-commits] [llvm/llvm-project] 6a60f1: [clang] Fix potential constant expression checking...

Eli Friedman via All-commits all-commits at lists.llvm.org
Thu Jul 17 13:14:56 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 6a60f18997d62b0e2842a921fcb6beb3e52ed823
      https://github.com/llvm/llvm-project/commit/6a60f18997d62b0e2842a921fcb6beb3e52ed823
  Author: Eli Friedman <efriedma at quicinc.com>
  Date:   2025-07-17 (Thu, 17 Jul 2025)

  Changed paths:
    M clang/lib/AST/ExprConstant.cpp
    M clang/test/SemaCXX/constant-expression-p2280r4.cpp
    M clang/test/SemaCXX/constexpr-never-constant.cpp

  Log Message:
  -----------
  [clang] Fix potential constant expression checking with constexpr-unknown. (#149227)

071765749a70b22fb62f2efc07a3f242ff5b4c52 improved constexpr-unknown
diagnostics, but potential constant expression checking broke in the
process: we produce diagnostics in more cases. Suppress the diagnostics
as appropriate.

This fix affects -Winvalid-constexpr and the enable_if attribute. (The
-Winvalid-constexpr diagnostic isn't really important right now, but it
will become important if we allow constexpr-unknown with pre-C++23
standards.)

Fixes #149041.  Fixes #149188.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list