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

    <tr>
        <th>Summary</th>
        <td>
            [libc++] Feature-test macros should reflect configurations like _LIBCPP_HAS_NO_FILESYSTEM
        </td>
    </tr>

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

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

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

<pre>
    Currently, FTMs like `__cpp_lib_filesystem` take into account availability markup like `_LIBCPP_AVAILABILITY_HAS_NO_FILESYSTEM_LIBRARY`. In other words, if the deployment target doesn't support `<filesystem>` the FTM will reflect that. That's good.

However, FTMs don't reflect carve-outs like `_LIBCPP_HAS_NO_FILESYSTEM`. In fact, generated tests like `libcxx/test/std/language.support/support.limits/support.limits.general/filesystem.version.compile.pass.cpp` are disabled with `// UNSUPPORTED: no-filesystem`, which means that we basically don't test the presence or absence of these FTMs in the case of carved-out configurations.

Instead, FTMs should reflect that the library has been configured without support for X or Y.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJx0VFtvozoQ_jXmZRREHEKTBx7SC9pI3d2qzR6dPkWDPYBPjY1skzT__sik6UXVSggsX76Z72LQe9UaopItrxnnWiprDDHO2fI2wTF01pVvk0lt5am8GZ0jE_SJ8Ruodj89aPVCwIpsvxfDsNeq3jdKkz_5QD0rMgj4QqBMsIBC2NEEwAMqjbXSKpygR_cyDh8o99vrm4eH_eafzfZ-c7293-6e9z82T_tfv_fV9v7u6flpd_cz7nrcPD6zIktha8CGjhwcrZM-9qUaCB2BpEHbU08mQEDXUgBpyRvGrwL4cRisC7EkW9x86nhxNzXdUWQHR6U1OGo0iQChw5DCrsPA-JWH1lqZsuyWZZvz-4c90oHcuzLSnmtdzgt0B5rZMfhvdL8xvDBrUIQI2JIhh4EkBPKfALSqxesr41WcZrzyQTJeaTTtiC2lbzTjwnmUatWr4L9NpOcCmvHqQ4z0QM4ra1Jh-0FpSgf0PhXDECVCRyCVx1qThKMK3aQlrxiv4M-vpz8PD78fd3e3bLEBY2dfMhEJHTslOugJjZ-EhSNBjV4J1Pr0Ll1kNZkxOPJkBIF1gPXbcLLZ01ltZaaNAv20Mokto9ogrGlUOzoMyhr_xbKt8YFQvlvmOztq-cXxCVWr2qE7QYceaiLzjvnGPZa5RKqxDv6NfT6niSwXcr1YY0LlvFgXeb4uilXSlUIIKtbNSqDIrxrkV7giMeeyobXMl3WRqJJnfDHPspxn2Twr0jkt53ktF7lcYdGIJcsz6lHpVOtDn1rXJsr7kcpixZdZorEm7S-3WtWC8evpmS62K-OhWT22nuWZVj74D5iggp7-B5-OLW-hIgyjo9nkSI_C2W9qfdX5HNG_BjwZnS67EAbPFptzbFoVurGOYYsR1ofLZzY4-x_Fe1BNHGN6J5r_BwAA__9wnZXi">