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

    <tr>
        <th>Summary</th>
        <td>
            Clang exposes C interfaces in C++ mode that it shouldn't
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            c++
      </td>
    </tr>

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

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

<pre>
    The C++ standard library is based on a particular revision of the C standard (e.g., C++23 is based on C17, C++17 is based on C11, C++14 is based on C99). The compiler provides some of the C standard library headers, but it exposes non-conforming interfaces from them in some language modes. For example:

https://godbolt.org/z/G8W7Gs1vE
https://godbolt.org/z/vbjs787TT
https://godbolt.org/z/Ks67KEoh3

For improved conformance, we should do a comprehensive review of the C standard library headers provided by Clang to ensure that we're exposing the proper interfaces in the proper language modes.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJyMk89uqzwQxZ_GbEZFYEggCxZNWrrottK3HvAAroyNPCZtv6e_cv6oaXSl2w1IHPtwzm9sZNajJWrEZi82TwmuYXK-eUTv7B6NmdEmnVNfzdtEcBByL-QeOKBV6BUY3Xn0X6AZOmRS4CwgLOiD7leDHjwdNWtnwQ0QosP3XiFrSsdUyMPVVxY_jA55dSPm1Z2Y34rlT3G3E3KXQszcu3nRhjws3h21IgZ2M_0lz7XLRKjIc3Tv1gA6AH0ujonBOvvQOzs4P2s7graB_IA9MQzezdFvBm3P_gbtuOJIMDtFnELrPNAnzoshUTyK7Elkl-cUwsLxm2yFbEenOmdC6vwoZPu_kO1L_V_1wvnx-XfLj907V3X19va75a-8rV6f3VTcRoph9RyBkYJLY7Q9RSYfBDy51ShQDvCE19NElvWRTuOmj3_DvQ5DQfcFh8gKggOyvHqCMGGADxKy8nRmH2lHw8W7hfwteG1vhTvoiWoKtSt2mFCTV7mUm6LOq2RqCKnKu7wnSXW_zYZMyjqncuhwhzT020Q3MpNlVmZlXmdFsUnrvuzrclPXeYEdYi3KjGbUJjXmOEeciWZeqamr7bZODHZk-HSlpOzPR1RIGe-Xb-KOh24dWZSZ0Rz42yPoYKg587geusNd3esdjBXPqHS4TMQKWYVk9aa5m7oO09qlvZuFbOPPLq-Hxbt36oOQ7Sk9C9meCvwJAAD__4IJVho">