LLParser: Fix failing nofpclass test
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Fri, 24 Feb 2023 12:40:41 +0000 (08:40 -0400)
committerMatt Arsenault <arsenm2@gmail.com>
Fri, 24 Feb 2023 12:46:11 +0000 (08:46 -0400)
llvm/lib/AsmParser/LLParser.cpp

index cb5c82b..673a34e 100644 (file)
@@ -2405,7 +2405,7 @@ unsigned LLParser::parseNoFPClassAttr() {
       // TODO: Disallow overlapping masks to avoid copy paste errors
     } else if (Mask == 0 && Lex.getKind() == lltok::APSInt &&
                !parseUInt64(Value)) {
-      if (Value == 0 || (Value & ~fcAllFlags) != 0) {
+      if (Value == 0 || (Value & ~static_cast<unsigned>(fcAllFlags)) != 0) {
         error(Lex.getLoc(), "invalid mask value for 'nofpclass'");
         return 0;
       }