Author: echristo Date: Thu Jul 13 18:42:57 2017 New Revision: 307988 URL: http://llvm.org/viewvc/llvm-project?rev=307988&view=rev Log: Change dyn_casts with unused variables to isa statements to avoid unused variables.
Modified: cfe/trunk/lib/CodeGen/CGStmtOpenMP.cpp cfe/trunk/lib/Sema/SemaDeclObjC.cpp Modified: cfe/trunk/lib/CodeGen/CGStmtOpenMP.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CGStmtOpenMP.cpp?rev=307988&r1=307987&r2=307988&view=diff ============================================================================== --- cfe/trunk/lib/CodeGen/CGStmtOpenMP.cpp (original) +++ cfe/trunk/lib/CodeGen/CGStmtOpenMP.cpp Thu Jul 13 18:42:57 2017 @@ -956,7 +956,7 @@ void CodeGenFunction::EmitOMPReductionCl auto *LHSVD = cast<VarDecl>(cast<DeclRefExpr>(*ILHS)->getDecl()); auto *RHSVD = cast<VarDecl>(cast<DeclRefExpr>(*IRHS)->getDecl()); - if (auto *OASE = dyn_cast<OMPArraySectionExpr>(IRef)) { + if (isa<OMPArraySectionExpr>(IRef)) { // Store the address of the original variable associated with the LHS // implicit variable. PrivateScope.addPrivate(LHSVD, [&RedCG, Count]() -> Address { @@ -965,7 +965,7 @@ void CodeGenFunction::EmitOMPReductionCl PrivateScope.addPrivate(RHSVD, [this, PrivateVD]() -> Address { return GetAddrOfLocalVar(PrivateVD); }); - } else if (auto *ASE = dyn_cast<ArraySubscriptExpr>(IRef)) { + } else if (isa<ArraySubscriptExpr>(IRef)) { // Store the address of the original variable associated with the LHS // implicit variable. PrivateScope.addPrivate(LHSVD, [&RedCG, Count]() -> Address { Modified: cfe/trunk/lib/Sema/SemaDeclObjC.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclObjC.cpp?rev=307988&r1=307987&r2=307988&view=diff ============================================================================== --- cfe/trunk/lib/Sema/SemaDeclObjC.cpp (original) +++ cfe/trunk/lib/Sema/SemaDeclObjC.cpp Thu Jul 13 18:42:57 2017 @@ -255,7 +255,7 @@ static void DiagnoseObjCImplementedDepre bool IsCategory = false; AvailabilityResult Availability = ND->getAvailability(); if (Availability != AR_Deprecated) { - if (const auto *MD = dyn_cast<ObjCMethodDecl>(ND)) { + if (isa<ObjCMethodDecl>(ND)) { if (Availability != AR_Unavailable) return; // Warn about implementing unavailable methods. _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits