<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/65689>65689</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
clang-cl.exe: False positive C++17 warning in C++14: out-of-line definition of constexpr static data member
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
dmitrykobets-msft
</td>
</tr>
</table>
<pre>
When compiling with C++14, I'm getting a warning that pertains only to C++17.
I tried this out with LLVM 17.0.0-rc4.
## Repro
```cpp
class A
{
static constexpr const int i{0};
};
constexpr const int A::i;
int main()
{
}
```
`clang-cl.exe <thefile.cpp> /std:c++14 -Weverything`
**Output**
warning: out-of-line definition of constexpr static data member is redundant in C++17 and is deprecated [-Wdeprecated-redundant-constexpr-static-def]
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJycU01vqzoQ_TVmMwKB-QoLFknzIlXq05Pe4nZt8AC-19jIHtrm3185JE1a3dWVLDPMcObjHEZ4r0aD2LLywMpjJFaarGvlrMidf9kOycezHyjqrDy3rxMa6O28KK3MCO-KJnhi_MD4ISsYf4JnxusZRiQKcQHvwplg0SQIFnQklPFgjT4D2U9onbD0yNL9M5BTKIEm5cGutBV4efnxL2R1kiZp7Pri-u315jnjOfyPi7Nf_FW6nX5ZNk-vhfdwC9eHzQAA8CRI9dBb4wk_FrdZoAyBYvUhZfWR5Ycb8G7_CbBneTjqDrjcITQLZRjfMd586yHk_Nr0t0l6LcwY9zrBDwSWP9GEg9KYhNnyf4DxkyfJ8n1_UwLiV3xDd6ZJmfF7Ph7OfystK2325r8qxfJ9YD62Q6yVQZA4KKNIWQN2eODoSpoUJGDGuUMHyoNDuRopAnPmri4II0NU4uKwF4QSWHmIX-_v8Scw_iwRbyViiQMrj48jRLLNZZM3IsI2q5oi41XVNNHU7oasLLAp85wX-VDtql3Z16JrqmbY8QZlpFqe8jxt0przoiibJOuFzGS3E1nVCyEkK1KchdKJ1m9zYt0YKe9XbKuy2jWRFh1qf1kVzg2-wyXIOA-b49qAibt19KxItfLk71lIkcb2UchA9Eloj7BYr0i94QNht7V5YLH4e2Wi1el2Ilp8-Dv5ifHTqGhau6S3M-On0OX1ES_O_sSeGD9dZvOMny6z_w4AAP__rLxFvw">