[libcxx] Apply pragma for silencing warning when building with clang-cl too
authorMartin Storsjö <martin@martin.st>
Fri, 5 Mar 2021 12:47:31 +0000 (14:47 +0200)
committerMartin Storsjö <martin@martin.st>
Fri, 5 Mar 2021 19:36:54 +0000 (21:36 +0200)
This silences warnings about unused functions (in an anonymous
namespace).

Differential Revision: https://reviews.llvm.org/D98036

libcxx/src/filesystem/filesystem_common.h

index 38d4eb0..22bf840 100644 (file)
@@ -35,7 +35,7 @@
 #endif
 #endif
 
-#if defined(__GNUC__)
+#if defined(__GNUC__) || defined(__clang__)
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wunused-function"
 #endif