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

    <tr>
        <th>Summary</th>
        <td>
            clang-cl ignores -Wreserved-macro-identifier
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
      </td>
    </tr>

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

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

<pre>
    C:\temp\cpp>clang-cl --version
clang version 17.0.6
Target: x86_64-pc-windows-msvc
Thread model: posix
InstalledDir: c:\devtools\LLVM\bin

test.cpp

`#define _CRT_SECURE_NO_DEPRECATE

#include<iostream>
using namespace std;

int main(int, char**)
{
  cout << "Hello world" << endl;

  return 0;
}`

clang-cl test.cpp -Wall -Wreserved-macro-identifier
test.cpp(2,9): warning: macro name is a reserved identifier [-Wreserved-macro-identifier]
    2 | #define _CRT_SECURE_NO_DEPRECATE
      |         ^
1 warning generated.

I also can't disable the warning via #pragma clang diagnostic ignored "-Wreserved-macro-identifier"
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyMU02PozgQ_TXFpURE7BjIgUOaJNqRZj_U27tzjIxdIV4ZG9kmPfvvVySku3cOrXEiQH7vlV99WMZoekfUgHgCsc_klC4-NMmHmMht6qzz-t-mBb4D0SYaRhCtGkfgB2Wl63NlMc-vFKLxDoo9FLvbPi5buK5Wxaq8Iy8y9JSA7_B7XZ7KTT6q_NU47V9jPsSrWliXQFLj4DXZmTv6aL7foS8uJmkt6b0JM6TutjRdk_c2gmi_fv37VxBtZxYz92eimFaz6w97UBbAuKazcYSn9vnl9Oeh_ev5cPrt99P-8Mfzod29HP4nYNw4ZSdNwFvjYwokB-ALZ4rG9ejkQHGUijAmDfzpo964hIM0DlhtXALWorrIAGx3-28XarVoEJWfEgJvgbcIjP1C1np89cFqYOwBkNP2h3MQA6UpOCzegWo_p_uB9Na8R2kw_yatxfxboEjhSjofpAo-N5pcMmdD4YdSspoBa7ezc77DVxmccf38edPdKoEmosRHQHwPhSCePjtJ7B-pIDKEai7Az7UKb2tWPBaIBVo_TGJPjoJMpFcfS_IFpY0elXTAqoTaRNlZwnShN-HVyNnJGGQ_SLwPujaydz4mo9D0zgfSc7c-y46xTDdcb_lWZtSsq4KvC14Kll2aYkNl3VVVUVdCbM-iKjd13Sl-lmeis9hkpmEF42vGivkn2IqtdcdoK7uOKVEqDpuCBmnsytrrsPKhz0yMEzVVuS6KzMqObHzc9dDMpLyb-gibwpqY4rssmWSpeZuTe27xswHJpmCbS0pjnK8lOwI79iZdpm6l_ADsOIdeXvkY_D-kErDjzV4Edrw5_C8AAP__t8VlTg">