From 260fe3eca6903f23fd017bafb7e555f4be8acf11 Mon Sep 17 00:00:00 2001 From: Zachary Turner Date: Thu, 14 Dec 2017 22:07:03 +0000 Subject: Fix many -Wsign-compare and -Wtautological-constant-compare warnings. Most of the -Wsign-compare warnings are due to the fact that enums are signed by default in the MS ABI, while the tautological comparison warnings trigger on x86 builds where sizeof(size_t) is 4 bytes, so N > numeric_limits::max() is always false. Differential Revision: https://reviews.llvm.org/D41256 llvm-svn: 320750 --- llvm/lib/Support/ARMAttributeParser.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm/lib/Support/ARMAttributeParser.cpp') diff --git a/llvm/lib/Support/ARMAttributeParser.cpp b/llvm/lib/Support/ARMAttributeParser.cpp index a9a0c1d1a4d..3d800eb7a96 100644 --- a/llvm/lib/Support/ARMAttributeParser.cpp +++ b/llvm/lib/Support/ARMAttributeParser.cpp @@ -592,7 +592,7 @@ void ARMAttributeParser::ParseAttributeList(const uint8_t *Data, bool Handled = false; for (unsigned AHI = 0, AHE = array_lengthof(DisplayRoutines); AHI != AHE && !Handled; ++AHI) { - if (DisplayRoutines[AHI].Attribute == Tag) { + if (uint64_t(DisplayRoutines[AHI].Attribute) == Tag) { (this->*DisplayRoutines[AHI].Routine)(ARMBuildAttrs::AttrType(Tag), Data, Offset); Handled = true; -- cgit v1.2.3