[Driver] Silence a -Wparentheses error. NFC
authorCraig Topper <craig.topper@sifive.com>
Tue, 27 Sep 2022 17:25:18 +0000 (10:25 -0700)
committerCraig Topper <craig.topper@sifive.com>
Tue, 27 Sep 2022 17:25:23 +0000 (10:25 -0700)
clang/lib/Driver/Driver.cpp

index 73ee0b9..a40a992 100644 (file)
@@ -635,7 +635,7 @@ static llvm::Triple computeTargetTriple(const Driver &D,
   // If target is MIPS adjust the target triple
   // accordingly to provided ABI name.
   if (Target.isMIPS()) {
-    if (A = Args.getLastArg(options::OPT_mabi_EQ)) {
+    if ((A = Args.getLastArg(options::OPT_mabi_EQ))) {
       StringRef ABIName = A->getValue();
       if (ABIName == "32") {
         Target = Target.get32BitArchVariant();
@@ -659,7 +659,7 @@ static llvm::Triple computeTargetTriple(const Driver &D,
   // If target is RISC-V adjust the target triple according to
   // provided architecture name
   if (Target.isRISCV()) {
-    if (A = Args.getLastArg(options::OPT_march_EQ)) {
+    if ((A = Args.getLastArg(options::OPT_march_EQ))) {
       StringRef ArchName = A->getValue();
       if (ArchName.startswith_insensitive("rv32"))
         Target.setArch(llvm::Triple::riscv32);