[llvm] r348256 - Fix MSVC "unknown pragma" warning. NFCI.
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 4 04:31:52 PST 2018
Author: rksimon
Date: Tue Dec 4 04:31:52 2018
New Revision: 348256
URL: http://llvm.org/viewvc/llvm-project?rev=348256&view=rev
Log:
Fix MSVC "unknown pragma" warning. NFCI.
Modified:
llvm/trunk/lib/Target/Hexagon/HexagonDepDecoders.h
Modified: llvm/trunk/lib/Target/Hexagon/HexagonDepDecoders.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Hexagon/HexagonDepDecoders.h?rev=348256&r1=348255&r2=348256&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Hexagon/HexagonDepDecoders.h (original)
+++ llvm/trunk/lib/Target/Hexagon/HexagonDepDecoders.h Tue Dec 4 04:31:52 2018
@@ -11,8 +11,10 @@
// clang-format off
+#if defined(__clang__)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wunused-function"
+#endif
static DecodeStatus s4_0ImmDecoder(MCInst &MI, unsigned tmp,
uint64_t, const void *Decoder) {
@@ -69,5 +71,9 @@ static DecodeStatus s4_2ImmDecoder(MCIns
signedDecoder<6>(MI, tmp, Decoder);
return MCDisassembler::Success;
}
+
+#if defined(__clang__)
#pragma clang diagnostic pop
+#endif
+
// clang-format on
More information about the llvm-commits
mailing list