/external/clang/lib/AST/ |
D | VTTBuilder.cpp | 64 const CXXRecordDecl *BaseDecl = in LayoutSecondaryVTTs() local 69 Layout.getBaseClassOffset(BaseDecl); in LayoutSecondaryVTTs() 72 LayoutVTT(BaseSubobject(BaseDecl, BaseOffset), /*BaseIsVirtual=*/false); in LayoutSecondaryVTTs() 90 const CXXRecordDecl *BaseDecl = in LayoutSecondaryVirtualPointers() local 100 if (!BaseDecl->isDynamicClass()) in LayoutSecondaryVirtualPointers() 108 if (!VBases.insert(BaseDecl).second) in LayoutSecondaryVirtualPointers() 111 BaseOffset = MostDerivedClassLayout.getVBaseClassOffset(BaseDecl); in LayoutSecondaryVirtualPointers() 117 Layout.getBaseClassOffset(BaseDecl); in LayoutSecondaryVirtualPointers() 120 Layout.getPrimaryBase() == BaseDecl) in LayoutSecondaryVirtualPointers() 130 (BaseDecl->getNumVBases() || BaseDeclIsMorallyVirtual)) { in LayoutSecondaryVirtualPointers() [all …]
|
D | CXXInheritance.cpp | 89 const CXXRecordDecl *BaseDecl = Base->getCanonicalDecl(); in isDerivedFrom() local 92 [this, BaseDecl](const CXXBaseSpecifier *Specifier, CXXBasePath &Path) { in isDerivedFrom() 93 return FindBaseClass(Specifier, Path, BaseDecl); in isDerivedFrom() 110 const CXXRecordDecl *BaseDecl = Base->getCanonicalDecl(); in isVirtuallyDerivedFrom() local 113 [this, BaseDecl](const CXXBaseSpecifier *Specifier, CXXBasePath &Path) { in isVirtuallyDerivedFrom() 114 return FindVirtualBaseClass(Specifier, Path, BaseDecl); in isVirtuallyDerivedFrom() 500 const CXXRecordDecl *BaseDecl = cast<CXXRecordDecl>(RT->getDecl()); in Collect() local 501 if (!BaseDecl->isPolymorphic()) in Collect() 507 Collect(BaseDecl, false, InVirtualSubobject, Overriders); in Collect() 519 CXXFinalOverriderMap *&MyVirtualOverriders = VirtualOverriders[BaseDecl]; in Collect() [all …]
|
D | RecordLayoutBuilder.cpp | 189 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in ComputeEmptySubobjectSizes() local 192 const ASTRecordLayout &Layout = Context.getASTRecordLayout(BaseDecl); in ComputeEmptySubobjectSizes() 193 if (BaseDecl->isEmpty()) { in ComputeEmptySubobjectSizes() 394 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in CanPlaceFieldSubobjectAtOffset() local 396 CharUnits BaseOffset = Offset + Layout.getBaseClassOffset(BaseDecl); in CanPlaceFieldSubobjectAtOffset() 397 if (!CanPlaceFieldSubobjectAtOffset(BaseDecl, Class, BaseOffset)) in CanPlaceFieldSubobjectAtOffset() 500 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in UpdateEmptyFieldSubobjects() local 502 CharUnits BaseOffset = Offset + Layout.getBaseClassOffset(BaseDecl); in UpdateEmptyFieldSubobjects() 503 UpdateEmptyFieldSubobjects(BaseDecl, Class, BaseOffset); in UpdateEmptyFieldSubobjects() 921 const CXXRecordDecl *BaseDecl = I.getType()->getAsCXXRecordDecl(); in ComputeBaseSubobjectInfo() local [all …]
|
D | VTableBuilder.cpp | 348 const CXXRecordDecl *BaseDecl = B.getType()->getAsCXXRecordDecl(); in ComputeBaseOffsets() local 354 if (SubobjectOffsets.count(std::make_pair(BaseDecl, 0))) in ComputeBaseOffsets() 360 BaseOffset = MostDerivedClassLayout.getVBaseClassOffset(BaseDecl); in ComputeBaseOffsets() 362 LayoutClassLayout.getVBaseClassOffset(BaseDecl); in ComputeBaseOffsets() 365 CharUnits Offset = Layout.getBaseClassOffset(BaseDecl); in ComputeBaseOffsets() 371 ComputeBaseOffsets(BaseSubobject(BaseDecl, BaseOffset), in ComputeBaseOffsets() 384 const CXXRecordDecl *BaseDecl = B.getType()->getAsCXXRecordDecl(); in dump() local 387 if (!BaseDecl->isPolymorphic()) in dump() 392 if (!VisitedVirtualBases.insert(BaseDecl).second) { in dump() 397 BaseOffset = MostDerivedClassLayout.getVBaseClassOffset(BaseDecl); in dump() [all …]
|
D | DeclCXX.cpp | 1453 CXXRecordDecl *BaseDecl in mayBeAbstract() local 1455 if (BaseDecl->isAbstract()) in mayBeAbstract()
|
/external/llvm-project/clang/lib/AST/ |
D | VTTBuilder.cpp | 67 const auto *BaseDecl = in LayoutSecondaryVTTs() local 72 Layout.getBaseClassOffset(BaseDecl); in LayoutSecondaryVTTs() 75 LayoutVTT(BaseSubobject(BaseDecl, BaseOffset), /*BaseIsVirtual=*/false); in LayoutSecondaryVTTs() 93 const auto *BaseDecl = in LayoutSecondaryVirtualPointers() local 103 if (!BaseDecl->isDynamicClass()) in LayoutSecondaryVirtualPointers() 111 if (!VBases.insert(BaseDecl).second) in LayoutSecondaryVirtualPointers() 114 BaseOffset = MostDerivedClassLayout.getVBaseClassOffset(BaseDecl); in LayoutSecondaryVirtualPointers() 120 Layout.getBaseClassOffset(BaseDecl); in LayoutSecondaryVirtualPointers() 123 Layout.getPrimaryBase() == BaseDecl) in LayoutSecondaryVirtualPointers() 133 (BaseDecl->getNumVBases() || BaseDeclIsMorallyVirtual)) { in LayoutSecondaryVirtualPointers() [all …]
|
D | CXXInheritance.cpp | 81 const CXXRecordDecl *BaseDecl = Base->getCanonicalDecl(); in isDerivedFrom() local 83 [BaseDecl](const CXXBaseSpecifier *Specifier, CXXBasePath &Path) { in isDerivedFrom() 84 return FindBaseClass(Specifier, Path, BaseDecl); in isDerivedFrom() 101 const CXXRecordDecl *BaseDecl = Base->getCanonicalDecl(); in isVirtuallyDerivedFrom() local 103 [BaseDecl](const CXXBaseSpecifier *Specifier, CXXBasePath &Path) { in isVirtuallyDerivedFrom() 104 return FindVirtualBaseClass(Specifier, Path, BaseDecl); in isVirtuallyDerivedFrom() 521 const CXXRecordDecl *BaseDecl = cast<CXXRecordDecl>(RT->getDecl()); in Collect() local 522 if (!BaseDecl->isPolymorphic()) in Collect() 528 Collect(BaseDecl, false, InVirtualSubobject, Overriders); in Collect() 540 CXXFinalOverriderMap *&MyVirtualOverriders = VirtualOverriders[BaseDecl]; in Collect() [all …]
|
D | RecordLayoutBuilder.cpp | 190 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in ComputeEmptySubobjectSizes() local 193 const ASTRecordLayout &Layout = Context.getASTRecordLayout(BaseDecl); in ComputeEmptySubobjectSizes() 194 if (BaseDecl->isEmpty()) { in ComputeEmptySubobjectSizes() 395 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in CanPlaceFieldSubobjectAtOffset() local 397 CharUnits BaseOffset = Offset + Layout.getBaseClassOffset(BaseDecl); in CanPlaceFieldSubobjectAtOffset() 398 if (!CanPlaceFieldSubobjectAtOffset(BaseDecl, Class, BaseOffset)) in CanPlaceFieldSubobjectAtOffset() 506 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in UpdateEmptyFieldSubobjects() local 508 CharUnits BaseOffset = Offset + Layout.getBaseClassOffset(BaseDecl); in UpdateEmptyFieldSubobjects() 509 UpdateEmptyFieldSubobjects(BaseDecl, Class, BaseOffset, in UpdateEmptyFieldSubobjects() 960 const CXXRecordDecl *BaseDecl = I.getType()->getAsCXXRecordDecl(); in ComputeBaseSubobjectInfo() local [all …]
|
D | VTableBuilder.cpp | 347 const CXXRecordDecl *BaseDecl = B.getType()->getAsCXXRecordDecl(); in ComputeBaseOffsets() local 353 if (SubobjectOffsets.count(std::make_pair(BaseDecl, 0))) in ComputeBaseOffsets() 359 BaseOffset = MostDerivedClassLayout.getVBaseClassOffset(BaseDecl); in ComputeBaseOffsets() 361 LayoutClassLayout.getVBaseClassOffset(BaseDecl); in ComputeBaseOffsets() 364 CharUnits Offset = Layout.getBaseClassOffset(BaseDecl); in ComputeBaseOffsets() 370 ComputeBaseOffsets(BaseSubobject(BaseDecl, BaseOffset), in ComputeBaseOffsets() 383 const CXXRecordDecl *BaseDecl = B.getType()->getAsCXXRecordDecl(); in dump() local 386 if (!BaseDecl->isPolymorphic()) in dump() 391 if (!VisitedVirtualBases.insert(BaseDecl).second) { in dump() 396 BaseOffset = MostDerivedClassLayout.getVBaseClassOffset(BaseDecl); in dump() [all …]
|
/external/llvm-project/clang-tools-extra/clang-tidy/cppcoreguidelines/ |
D | SlicingCheck.cpp | 77 const CXXRecordDecl &BaseDecl) { in DiagnoseSlicedOverriddenMethods() argument 78 if (DerivedDecl.getCanonicalDecl() == BaseDecl.getCanonicalDecl()) in DiagnoseSlicedOverriddenMethods() 88 << &DerivedDecl << &BaseDecl << Method; in DiagnoseSlicedOverriddenMethods() 96 DiagnoseSlicedOverriddenMethods(Call, *BaseRecord, BaseDecl); in DiagnoseSlicedOverriddenMethods() 102 const auto *BaseDecl = Result.Nodes.getNodeAs<CXXRecordDecl>("BaseDecl"); in check() local 106 assert(BaseDecl != nullptr); in check() 119 DiagnoseSlicedOverriddenMethods(*Call, *DerivedDecl, *BaseDecl); in check() 123 BaseDecl->getASTContext().getASTRecordLayout(BaseDecl); in check() 131 << DerivedDecl << BaseDecl << static_cast<int>(StateSize.getQuantity()); in check()
|
D | SlicingCheck.h | 37 const CXXRecordDecl &BaseDecl);
|
/external/clang/lib/CodeGen/ |
D | CGRecordLayoutBuilder.cpp | 444 const CXXRecordDecl *BaseDecl = Layout.getPrimaryBase(); in accumulateBases() local 446 getStorageType(BaseDecl), BaseDecl)); in accumulateBases() 455 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in accumulateBases() local 456 if (!BaseDecl->isEmpty() && in accumulateBases() 457 !Context.getASTRecordLayout(BaseDecl).getNonVirtualSize().isZero()) in accumulateBases() 458 Members.push_back(MemberInfo(Layout.getBaseClassOffset(BaseDecl), in accumulateBases() 459 MemberInfo::Base, getStorageType(BaseDecl), BaseDecl)); in accumulateBases() 481 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in accumulateVBases() local 482 if (BaseDecl->isEmpty()) in accumulateVBases() 486 if (Context.isNearlyEmpty(BaseDecl) && !hasOwnStorage(RD, BaseDecl)) in accumulateVBases() [all …]
|
D | ItaniumCXXABI.cpp | 2710 const CXXRecordDecl *BaseDecl = in CanUseSingleInheritance() local 2712 if (!BaseDecl->isEmpty() && in CanUseSingleInheritance() 2713 BaseDecl->isDynamicClass() != RD->isDynamicClass()) in CanUseSingleInheritance() 3152 const CXXRecordDecl *BaseDecl = in ComputeVMIClassTypeInfoFlags() local 3157 if (!Bases.VirtualBases.insert(BaseDecl).second) { in ComputeVMIClassTypeInfoFlags() 3162 if (Bases.NonVirtualBases.count(BaseDecl)) in ComputeVMIClassTypeInfoFlags() 3167 if (!Bases.NonVirtualBases.insert(BaseDecl).second) { in ComputeVMIClassTypeInfoFlags() 3172 if (Bases.VirtualBases.count(BaseDecl)) in ComputeVMIClassTypeInfoFlags() 3178 for (const auto &I : BaseDecl->bases()) in ComputeVMIClassTypeInfoFlags() 3241 const CXXRecordDecl *BaseDecl = in BuildVMIClassTypeInfo() local [all …]
|
D | CGClass.cpp | 162 const CXXRecordDecl *BaseDecl = in computeNonVirtualBaseClassOffset() local 166 Offset += Layout.getBaseClassOffset(BaseDecl); in computeNonVirtualBaseClassOffset() 168 RD = BaseDecl; in computeNonVirtualBaseClassOffset() 2511 CXXRecordDecl *BaseDecl in getVTablePointers() local 2515 if (!BaseDecl->isDynamicClass()) in getVTablePointers() 2524 if (!VBases.insert(BaseDecl).second) in getVTablePointers() 2530 BaseOffset = Layout.getVBaseClassOffset(BaseDecl); in getVTablePointers() 2536 BaseOffset = Base.getBaseOffset() + Layout.getBaseClassOffset(BaseDecl); in getVTablePointers() 2538 OffsetFromNearestVBase + Layout.getBaseClassOffset(BaseDecl); in getVTablePointers() 2539 BaseDeclIsNonVirtualPrimaryBase = Layout.getPrimaryBase() == BaseDecl; in getVTablePointers() [all …]
|
/external/llvm-project/clang/lib/CodeGen/ |
D | CGRecordLayoutBuilder.cpp | 507 const CXXRecordDecl *BaseDecl = Layout.getPrimaryBase(); in accumulateBases() local 509 getStorageType(BaseDecl), BaseDecl)); in accumulateBases() 518 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in accumulateBases() local 519 if (!BaseDecl->isEmpty() && in accumulateBases() 520 !Context.getASTRecordLayout(BaseDecl).getNonVirtualSize().isZero()) in accumulateBases() 521 Members.push_back(MemberInfo(Layout.getBaseClassOffset(BaseDecl), in accumulateBases() 522 MemberInfo::Base, getStorageType(BaseDecl), BaseDecl)); in accumulateBases() 661 const CXXRecordDecl *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in accumulateVBases() local 662 if (BaseDecl->isEmpty()) in accumulateVBases() 666 if (Context.isNearlyEmpty(BaseDecl) && !hasOwnStorage(RD, BaseDecl)) in accumulateVBases() [all …]
|
D | CGClass.cpp | 183 const auto *BaseDecl = in computeNonVirtualBaseClassOffset() local 187 Offset += Layout.getBaseClassOffset(BaseDecl); in computeNonVirtualBaseClassOffset() 189 RD = BaseDecl; in computeNonVirtualBaseClassOffset() 2565 auto *BaseDecl = in getVTablePointers() local 2569 if (!BaseDecl->isDynamicClass()) in getVTablePointers() 2578 if (!VBases.insert(BaseDecl).second) in getVTablePointers() 2584 BaseOffset = Layout.getVBaseClassOffset(BaseDecl); in getVTablePointers() 2590 BaseOffset = Base.getBaseOffset() + Layout.getBaseClassOffset(BaseDecl); in getVTablePointers() 2592 OffsetFromNearestVBase + Layout.getBaseClassOffset(BaseDecl); in getVTablePointers() 2593 BaseDeclIsNonVirtualPrimaryBase = Layout.getPrimaryBase() == BaseDecl; in getVTablePointers() [all …]
|
D | ItaniumCXXABI.cpp | 3358 auto *BaseDecl = in CanUseSingleInheritance() local 3360 if (!BaseDecl->isEmpty() && in CanUseSingleInheritance() 3361 BaseDecl->isDynamicClass() != RD->isDynamicClass()) in CanUseSingleInheritance() 3843 auto *BaseDecl = in ComputeVMIClassTypeInfoFlags() local 3848 if (!Bases.VirtualBases.insert(BaseDecl).second) { in ComputeVMIClassTypeInfoFlags() 3853 if (Bases.NonVirtualBases.count(BaseDecl)) in ComputeVMIClassTypeInfoFlags() 3858 if (!Bases.NonVirtualBases.insert(BaseDecl).second) { in ComputeVMIClassTypeInfoFlags() 3863 if (Bases.VirtualBases.count(BaseDecl)) in ComputeVMIClassTypeInfoFlags() 3869 for (const auto &I : BaseDecl->bases()) in ComputeVMIClassTypeInfoFlags() 3942 auto *BaseDecl = in BuildVMIClassTypeInfo() local [all …]
|
/external/llvm-project/clang-tools-extra/clang-tidy/bugprone/ |
D | ParentVirtualCallCheck.cpp | 33 auto *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in isParentOf() local 34 assert(BaseDecl); in isParentOf() 35 return ParentCanonicalDecl == BaseDecl->getCanonicalDecl(); in isParentOf() 44 const auto *BaseDecl = Base.getType()->getAsCXXRecordDecl(); in getParentsByGrandParent() local 46 MemberDecl.getCorrespondingMethodInClass(BaseDecl); in getParentsByGrandParent()
|
/external/llvm-project/clang/lib/StaticAnalyzer/Core/ |
D | Store.cpp | 280 const CXXRecordDecl *BaseDecl = BaseType->getPointeeCXXRecordDecl(); in evalDerivedToBase() local 281 if (!BaseDecl) in evalDerivedToBase() 282 BaseDecl = BaseType->getAsCXXRecordDecl(); in evalDerivedToBase() 283 assert(BaseDecl && "not a C++ object?"); in evalDerivedToBase() 289 if (SR->getSymbol()->getType()->getPointeeCXXRecordDecl() == BaseDecl) in evalDerivedToBase() 296 BaseDecl, cast<SubRegion>(DerivedReg), IsVirtual); in evalDerivedToBase()
|
/external/clang/lib/StaticAnalyzer/Core/ |
D | Store.cpp | 269 const CXXRecordDecl *BaseDecl = BaseType->getPointeeCXXRecordDecl(); in evalDerivedToBase() local 270 if (!BaseDecl) in evalDerivedToBase() 271 BaseDecl = BaseType->getAsCXXRecordDecl(); in evalDerivedToBase() 272 assert(BaseDecl && "not a C++ object?"); in evalDerivedToBase() 275 MRMgr.getCXXBaseObjectRegion(BaseDecl, DerivedRegVal->getRegion(), in evalDerivedToBase()
|
/external/clang/test/SemaCXX/ |
D | typo-correction.cpp | 114 struct BaseDecl { struct 117 struct TestRedecl : public BaseDecl {
|
/external/llvm-project/clang/test/SemaCXX/ |
D | typo-correction.cpp | 115 struct BaseDecl { struct 118 struct TestRedecl : public BaseDecl {
|
/external/clang/lib/Sema/ |
D | SemaLookup.cpp | 2544 CXXRecordDecl *BaseDecl = cast<CXXRecordDecl>(BaseType->getDecl()); in addAssociatedClassesAndNamespaces() local 2545 if (Result.Classes.insert(BaseDecl)) { in addAssociatedClassesAndNamespaces() 2547 DeclContext *BaseCtx = BaseDecl->getDeclContext(); in addAssociatedClassesAndNamespaces() 2551 if (BaseDecl->bases_begin() != BaseDecl->bases_end()) in addAssociatedClassesAndNamespaces() 2552 Bases.push_back(BaseDecl); in addAssociatedClassesAndNamespaces()
|
D | SemaDeclCXX.cpp | 1379 if (CXXRecordDecl *BaseDecl = BaseType->getAsCXXRecordDecl()) { in CheckBaseSpecifier() local 1380 if (BaseDecl->getCanonicalDecl() == Class->getCanonicalDecl() || in CheckBaseSpecifier() 1381 ((BaseDecl = BaseDecl->getDefinition()) && in CheckBaseSpecifier() 1382 findCircularInheritance(Class, BaseDecl))) { in CheckBaseSpecifier() 1386 if (BaseDecl->getCanonicalDecl() != Class->getCanonicalDecl()) in CheckBaseSpecifier() 1387 Diag(BaseDecl->getLocation(), diag::note_previous_decl) in CheckBaseSpecifier() 1433 RecordDecl *BaseDecl = BaseType->getAs<RecordType>()->getDecl(); in CheckBaseSpecifier() local 1434 assert(BaseDecl && "Record type has no declaration"); in CheckBaseSpecifier() 1435 BaseDecl = BaseDecl->getDefinition(); in CheckBaseSpecifier() 1436 assert(BaseDecl && "Base type is not incomplete, but has no definition"); in CheckBaseSpecifier() [all …]
|
/external/llvm-project/clang/lib/Sema/ |
D | SemaLookup.cpp | 2748 CXXRecordDecl *BaseDecl = cast<CXXRecordDecl>(BaseType->getDecl()); in addAssociatedClassesAndNamespaces() local 2749 if (Result.addClassTransitive(BaseDecl)) { in addAssociatedClassesAndNamespaces() 2751 DeclContext *BaseCtx = BaseDecl->getDeclContext(); in addAssociatedClassesAndNamespaces() 2755 if (BaseDecl->bases_begin() != BaseDecl->bases_end()) in addAssociatedClassesAndNamespaces() 2756 Bases.push_back(BaseDecl); in addAssociatedClassesAndNamespaces()
|