<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/129730>129730</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            Value of `__cpp_constexpr` is incorrect for `-std=c++20`
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            new issue
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          elbeno
      </td>
    </tr>
</table>

<pre>
    When compiling with `-std=c++20`, clang defines `__cpp_constexpr` to be `201907L`, and it should be `202002L`.

https://godbolt.org/z/G6v7EvEfe

Clearly clang has support for https://wg21.link/P1330.

So the value of `__cpp_constexpr` in C++20 should be 202002L as given by https://wg21.link/p2493 and https://isocpp.org/std/standing-documents/sd-6-sg10-feature-test-recommendations#__cpp_constexpr

</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyEkkmPnDAQhX-NuVi0ysU2HDj0LJ1LDpEiJceRsQtwYmxkm550fn1ED5NkRlkuIFGvqvhePRmjGR1Rx6pbVt1nck2TDx3ZnpzPeq8v3eeJHFd-Xow1buRPJk2c1ZDHpFlxrxjeMrxFYDUwvOPKSjdyTYNxFDfd46NalkflXUz0bQmsBp4872mrIYgWmvd7q3Sam8Tj5FerfyoQADfFgcGRwXFKaYmsODI8MTyNXvfepoMPI8PTd4and_W5eTg_DPQsv7Mkg73svzXJyOO6LD4kPvjAXw97GlEcrHFfGZ4-iKJ4WfnR8zQRP0u7EvfDX6CM43cvXvzGsANwGflozuR4f_nH2gXLtrga8VpjolfLsmNuxm9P6bRxY669WmdyKW4fdV7ncRSQDyTTGihPFFMeSPl5JqdlMt5FhsVbADhmuit0W7Qyo040pRBQljdlNnXQ1rJWNdYgJVJV9xVVVN3oZmhF0zSUmQ4BKyigFDXcQHlQwyCkaHpVDEUDAlkJNEtjD9ae5w0iMzGu1AlsmwIyK3uy8ZpAREdP_FpliFsgQ7c15f06RlaCNTHFX2OSSZa6T_85TOTGKR8Cqeer_zm82Rps9yZdJk1rf1B-Znjalu6vfAn-C6l0PUxcaXN-Zzl3-CMAAP__UF4KCA">