Fix unused variable warning from D134529
authorErich Keane <erich.keane@intel.com>
Mon, 10 Oct 2022 18:42:19 +0000 (11:42 -0700)
committerErich Keane <erich.keane@intel.com>
Mon, 10 Oct 2022 18:42:43 +0000 (11:42 -0700)
clang/lib/Sema/SemaOverload.cpp

index b3f98a0..c7e66d1 100644 (file)
@@ -931,7 +931,7 @@ static bool shouldAddReversedEqEq(Sema &S, SourceLocation OpLoc,
   // target.
   DeclarationName NotEqOp = S.Context.DeclarationNames.getCXXOperatorName(
       OverloadedOperatorKind::OO_ExclaimEqual);
-  if (auto *MD = dyn_cast<CXXMethodDecl>(EqFD)) {
+  if (isa<CXXMethodDecl>(EqFD)) {
     // If F is a class member, search scope is class type of first operand.
     QualType RHS = FirstOperand->getType();
     auto *RHSRec = RHS->getAs<RecordType>();