[PATCH] D65859: [LLVM][Alignment] Fix MSVC warning
Simon Pilgrim via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 15 09:33:23 PDT 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL369016: [LLVM][Alignment] Fix MSVC potential division by 0 warning (PR42911) (authored by RKSimon, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D65859?vs=215381&id=215419#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65859/new/
https://reviews.llvm.org/D65859
Files:
llvm/trunk/unittests/Support/AlignmentTest.cpp
Index: llvm/trunk/unittests/Support/AlignmentTest.cpp
===================================================================
--- llvm/trunk/unittests/Support/AlignmentTest.cpp
+++ llvm/trunk/unittests/Support/AlignmentTest.cpp
@@ -11,6 +11,12 @@
#include <vector>
+#ifdef _MSC_VER
+// Disable warnings about potential divide by 0.
+#pragma warning(push)
+#pragma warning(disable : 4723)
+#endif
+
using namespace llvm;
namespace {
@@ -298,3 +304,7 @@
#endif // NDEBUG
} // end anonymous namespace
+
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D65859.215419.patch
Type: text/x-patch
Size: 556 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190815/f868b655/attachment.bin>
More information about the llvm-commits
mailing list