[clang] 207f153 - [InstallAPI] Condense std::pair unwrapping in CategoryRecord NFC
Cyndy Ishida via cfe-commits
cfe-commits at lists.llvm.org
Tue Apr 2 09:18:33 PDT 2024
Author: Cyndy Ishida
Date: 2024-04-02T09:17:06-07:00
New Revision: 207f1531d611b8add27b94e756e0bc7eb864babf
URL: https://github.com/llvm/llvm-project/commit/207f1531d611b8add27b94e756e0bc7eb864babf
DIFF: https://github.com/llvm/llvm-project/commit/207f1531d611b8add27b94e756e0bc7eb864babf.diff
LOG: [InstallAPI] Condense std::pair unwrapping in CategoryRecord NFC
Added:
Modified:
clang/lib/InstallAPI/Visitor.cpp
Removed:
################################################################################
diff --git a/clang/lib/InstallAPI/Visitor.cpp b/clang/lib/InstallAPI/Visitor.cpp
index 6476c5107cb5cc..cf3aaa4c6ec931 100644
--- a/clang/lib/InstallAPI/Visitor.cpp
+++ b/clang/lib/InstallAPI/Visitor.cpp
@@ -205,10 +205,10 @@ bool InstallAPIVisitor::VisitObjCCategoryDecl(const ObjCCategoryDecl *D) {
const ObjCInterfaceDecl *InterfaceD = D->getClassInterface();
const StringRef InterfaceName = InterfaceD->getName();
- std::pair<ObjCCategoryRecord *, FrontendAttrs *> Category =
- Ctx.Slice->addObjCCategory(InterfaceName, CategoryName, Avail, D,
- *Access);
- recordObjCInstanceVariables(D->getASTContext(), Category.first, InterfaceName,
+ ObjCCategoryRecord *CategoryRecord =
+ Ctx.Slice->addObjCCategory(InterfaceName, CategoryName, Avail, D, *Access)
+ .first;
+ recordObjCInstanceVariables(D->getASTContext(), CategoryRecord, InterfaceName,
D->ivars());
return true;
}
More information about the cfe-commits
mailing list