[libcxx-commits] [PATCH] D114242: [libc++] Fix some tests that were broken in the single-threaded configuration

Joe Loser via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri Nov 19 08:37:02 PST 2021


jloser added inline comments.


================
Comment at: libcxx/utils/generate_feature_test_macro_components.py:657
+# For example, when threads are not supported, any test that includes
+# <thread> should be marked as UNSUPPORTED, because including <thread>
+# is a hard error in that case.
----------------
ldionne wrote:
> jloser wrote:
> > I find it interesting that including `<thread>` would be a hard error rather than a no-op like other "unsupported features" when it comes to including other headers (like ranges, concepts, etc.). No action required, but just an observation.
> We do have some inconsistency around that, however all features like "no-localization", "no-wide-characters", "no-random-device" are hard errors, and I think it makes the most sense. Indeed, what we're trying to model here is a platform that literally does not support these features. For example, on some platforms, you literally can't include `<wchar.h>`, because there is no such header. Putting an `#error` on our side is what models that best IMO.
> 
> Features like concepts are somewhat different, in that it's a matter of compiler support, where we try to be flexible and accommodate compilers that have incomplete support for X.
Makes sense - thanks for the discussion.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D114242/new/

https://reviews.llvm.org/D114242



More information about the libcxx-commits mailing list