<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Dec 10, 2018, at 20:14, Casey Carter <<a href="mailto:cacarter@microsoft.com" class="">cacarter@microsoft.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div style="caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class="">I don't have context for the original issue, but our test selector does inspect some of the LIT control comments. Specifically, it skips tests with any of the comments:</div><div style="caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><span class=""><br class=""></span></div><blockquote style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; margin: 0px 0px 0px 40px; border: none; padding: 0px;" class=""><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><span class="">// REQUIRES: c++11</span></div><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><div class="">// REQUIRES: c++11 || c++14</div></div><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><div class="">// REQUIRES: c++98 || c++03</div></div><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><div class="">// REQUIRES: c++98 || c++03 || c++11 || c++14</div></div><div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><div class="">// UNSUPPORTED: c++14, c++17, c++2a</div></div></blockquote><div style="caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class=""><span class=""></span><br class=""></div><div style="caret-color: rgb(0, 0, 0); font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt;" class="">So if were talking about something that doesn't touch those, it won't affect our typical usage.</div><div id="signature" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><div id="divtagdefaultwrapper" style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; background-color: rgb(255, 255, 255);" class=""><div style="margin-top: 0px; margin-bottom: 0px;" class=""><br class=""></div></div></div><div id="appendonsend" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""></div><hr tabindex="-1" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; display: inline-block; width: 1761.046875px;" class=""><span style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none; float: none; display: inline !important;" class=""></span><div id="divRplyFwdMsg" dir="ltr" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;" class=""><font face="Calibri, sans-serif" style="font-size: 11pt;" class=""><b class="">From:</b><span class="Apple-converted-space"> </span>Stephan T. Lavavej<br class=""><b class="">Sent:</b><span class="Apple-converted-space"> </span>Monday, December 10, 2018 15:43<br class=""><b class="">To:</b><span class="Apple-converted-space"> </span>Jonathan Wakely; <a href="mailto:ldionne@apple.com" class="">ldionne@apple.com</a><br class=""><b class="">Cc:</b><span class="Apple-converted-space"> </span>Richard Smith; Marshall Clow; <a href="mailto:libcxx-dev@lists.llvm.org" class="">libcxx-dev@lists.llvm.org</a>; Billy O'Neal (VC LIBS); Casey Carter<br class=""><b class="">Subject:</b><span class="Apple-converted-space"> </span>RE: [libcxx-dev] How to check for a feature-test macro</font><div class=""> </div></div><div class="BodyFragment" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><font size="2" class=""><span style="font-size: 11pt;" class=""><div class="PlainText">(+Casey who also works on this)<br class=""><br class="">When running libcxx's tests against MSVC's STL, we have an MSVC-internal skipped_tests.txt (full content available if requested) which says:<br class=""><br class=""># *** MISSING STL FEATURES ***<br class=""># C++20 P0122R7 "<span>"<br class="">upstream\test\std\containers\views\types.pass.cpp<br class="">[...]<br class=""><br class=""># C++20 P0355R7 "<chrono> Calendars And Time Zones"<br class="">upstream\test\std\utilities\time\days.pass.cpp<br class="">[...]<br class=""><br class="">Updating this requires minimal effort. It's more problematic when existing tests are modified to test new features, since we have to skip the entire test even if only a small part is affected.<br class=""><br class="">Guarding tests with feature-test macros in their source code (as opposed to "the LIT level", which I believe is machinery that we don't use) would be ideal, I think.<br class=""></div></span></font></div></div></blockquote><div><br class=""></div><div>Why do you not use `lit` to run the test suite?</div><div><br class=""></div><div>As I understand it, MSVC would prefer disabling tests that are not supported using `#if !defined(<feature>)`. This can be made to work, but what I don't like is that it removes visibility into what tests are passing and which ones are not supported. Right now, we can easily tell how many tests are unsupported by an implementation because those are marked by LIT as `UNSUPPORTED`. If we start using feature test macros to disable tests, we lose that.</div><div><br class=""></div><div>Louis</div><br class=""><blockquote type="cite" class=""><div class=""><div class="BodyFragment" style="caret-color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration: none;"><font size="2" class=""><span style="font-size: 11pt;" class=""><div class="PlainText"><br class="">The annoying thing is when features are added without corresponding feature-test macros. There's a bunch of those right now. We'll probably need the skip-tests approach for those.<br class=""><br class="">STL<br class=""><br class="">-----Original Message-----<br class="">From: Jonathan Wakely <<a href="mailto:cxx@kayari.org" class="">cxx@kayari.org</a>><span class="Apple-converted-space"> </span><br class="">Sent: Monday, December 10, 2018 12:10 PM<br class="">To: <a href="mailto:ldionne@apple.com" class="">ldionne@apple.com</a><br class="">Cc: Richard Smith <<a href="mailto:richard@metafoo.co.uk" class="">richard@metafoo.co.uk</a>>; Marshall Clow <<a href="mailto:mclow.lists@gmail.com" class="">mclow.lists@gmail.com</a>>; <a href="mailto:libcxx-dev@lists.llvm.org" class="">libcxx-dev@lists.llvm.org</a>; Stephan T. Lavavej <<a href="mailto:stl@exchange.microsoft.com" class="">stl@exchange.microsoft.com</a>>; Billy O'Neal (VC LIBS) <<a href="mailto:bion@microsoft.com" class="">bion@microsoft.com</a>><br class="">Subject: Re: [libcxx-dev] How to check for a feature-test macro<br class=""><br class="">On Mon, 10 Dec 2018 at 19:47, Louis Dionne wrote:<br class="">> We should also see how other implementations that use our test suite feel about this (CCing them).<br class=""><br class="">I only use your tests a few times a year, run by hand. If I get a load of FAILs because I've not implemented something yet and you have, that's not a problem. I don't expect to get 100% green when I run your tests.</div></span></font></div></div></blockquote></div><br class=""></body></html>