G M: Provides the _LIBCPP_WARNING macro, to be used for MSVC only, since that compiler doesn't support #warning.
llvm-svn: 191980
Cr-Mirrored-From: sso://chromium.googlesource.com/_direct/external/github.com/llvm/llvm-project
Cr-Mirrored-Commit: 80b84d4c268b75994524b00db7a1437b070e98a8
diff --git a/src/thread.cpp b/src/thread.cpp
index cdfa2fd..338a8a2 100644
--- a/src/thread.cpp
+++ b/src/thread.cpp
@@ -89,7 +89,11 @@
#else // defined(CTL_HW) && defined(HW_NCPU)
// TODO: grovel through /proc or check cpuid on x86 and similar
// instructions on other architectures.
-#warning hardware_concurrency not yet implemented
+# if defined(_MSC_VER) && ! defined(__clang__)
+ _LIBCPP_WARNING("hardware_concurrency not yet implemented")
+# else
+# warning hardware_concurrency not yet implemented
+# endif
return 0; // Means not computable [thread.thread.static]
#endif // defined(CTL_HW) && defined(HW_NCPU)
}