• Home
  • Raw
  • Download

Lines Matching refs:Entity

149   AccessTarget(const AccessedEntity &Entity)  in AccessTarget()
150 : AccessedEntity(Entity) { in AccessTarget()
1260 AccessTarget &Entity) { in DiagnoseBadAccess() argument
1261 const CXXRecordDecl *NamingClass = Entity.getNamingClass(); in DiagnoseBadAccess()
1262 const CXXRecordDecl *DeclaringClass = Entity.getDeclaringClass(); in DiagnoseBadAccess()
1263 NamedDecl *D = (Entity.isMemberAccess() ? Entity.getTargetDecl() : nullptr); in DiagnoseBadAccess()
1265 S.Diag(Loc, Entity.getDiag()) in DiagnoseBadAccess()
1266 << (Entity.getAccess() == AS_protected) in DiagnoseBadAccess()
1270 DiagnoseAccessPath(S, EC, Entity); in DiagnoseBadAccess()
1295 AccessTarget &Entity) { in IsMicrosoftUsingDeclarationAccessBug() argument
1297 dyn_cast<UsingShadowDecl>(Entity.getTargetDecl())) { in IsMicrosoftUsingDeclarationAccessBug()
1298 const NamedDecl *OrigDecl = Entity.getTargetDecl()->getUnderlyingDecl(); in IsMicrosoftUsingDeclarationAccessBug()
1299 if (Entity.getTargetDecl()->getAccess() == AS_private && in IsMicrosoftUsingDeclarationAccessBug()
1315 AccessTarget &Entity) { in IsAccessible() argument
1317 const CXXRecordDecl *NamingClass = Entity.getEffectiveNamingClass(); in IsAccessible()
1319 AccessSpecifier UnprivilegedAccess = Entity.getAccess(); in IsAccessible()
1327 switch (HasAccess(S, EC, NamingClass, UnprivilegedAccess, Entity)) { in IsAccessible()
1343 AccessTarget::SavedInstanceContext _ = Entity.saveInstanceContext(); in IsAccessible()
1349 if (Entity.isMemberAccess()) { in IsAccessible()
1352 NamedDecl *Target = Entity.getTargetDecl(); in IsAccessible()
1353 const CXXRecordDecl *DeclaringClass = Entity.getDeclaringClass(); in IsAccessible()
1356 switch (HasAccess(S, EC, DeclaringClass, FinalAccess, Entity)) { in IsAccessible()
1364 Entity.suppressInstanceContext(); in IsAccessible()
1376 assert(Entity.getDeclaringClass() != NamingClass); in IsAccessible()
1380 CXXBasePath *Path = FindBestPath(S, EC, Entity, FinalAccess, Paths); in IsAccessible()
1394 const AccessTarget &Entity) { in DelayDependentAccess() argument
1400 Entity.isMemberAccess(), in DelayDependentAccess()
1401 Entity.getAccess(), in DelayDependentAccess()
1402 Entity.getTargetDecl(), in DelayDependentAccess()
1403 Entity.getNamingClass(), in DelayDependentAccess()
1404 Entity.getBaseObjectType(), in DelayDependentAccess()
1405 Entity.getDiag()); in DelayDependentAccess()
1412 AccessTarget &Entity) { in CheckEffectiveAccess() argument
1413 assert(Entity.getAccess() != AS_public && "called for public access!"); in CheckEffectiveAccess()
1415 switch (IsAccessible(S, EC, Entity)) { in CheckEffectiveAccess()
1417 DelayDependentAccess(S, EC, Loc, Entity); in CheckEffectiveAccess()
1422 IsMicrosoftUsingDeclarationAccessBug(S, Loc, Entity)) in CheckEffectiveAccess()
1424 if (!Entity.isQuiet()) in CheckEffectiveAccess()
1425 DiagnoseBadAccess(S, Loc, EC, Entity); in CheckEffectiveAccess()
1437 AccessTarget &Entity) { in CheckAccess() argument
1439 if (Entity.getAccess() == AS_public) in CheckAccess()
1454 S.DelayedDiagnostics.add(DelayedDiagnostic::makeAccess(Loc, Entity)); in CheckAccess()
1459 switch (CheckEffectiveAccess(S, EC, Loc, Entity)) { in CheckAccess()
1513 AccessTarget Entity(Context, in HandleDependentAccessCheck() local
1518 Entity.setDiag(DD.getDiagnostic()); in HandleDependentAccessCheck()
1519 CheckAccess(*this, Loc, Entity); in HandleDependentAccessCheck()
1521 AccessTarget Entity(Context, in HandleDependentAccessCheck() local
1526 Entity.setDiag(DD.getDiagnostic()); in HandleDependentAccessCheck()
1527 CheckAccess(*this, Loc, Entity); in HandleDependentAccessCheck()
1538 AccessTarget Entity(Context, AccessTarget::Member, E->getNamingClass(), in CheckUnresolvedLookupAccess() local
1540 Entity.setDiag(diag::err_access) << E->getSourceRange(); in CheckUnresolvedLookupAccess()
1542 return CheckAccess(*this, E->getNameLoc(), Entity); in CheckUnresolvedLookupAccess()
1557 AccessTarget Entity(Context, AccessTarget::Member, E->getNamingClass(), in CheckUnresolvedMemberAccess() local
1559 Entity.setDiag(diag::err_access) << E->getSourceRange(); in CheckUnresolvedMemberAccess()
1561 return CheckAccess(*this, E->getMemberLoc(), Entity); in CheckUnresolvedMemberAccess()
1575 AccessTarget Entity(Context, AccessTarget::Member, NamingClass, Found, in isMemberAccessibleForDeletion() local
1579 Entity.setDiag(Diag); in isMemberAccessibleForDeletion()
1581 switch (CheckAccess(*this, Loc, Entity)) { in isMemberAccessibleForDeletion()
1605 AccessTarget Entity(Context, AccessTarget::Member, NamingClass, in CheckDestructorAccess() local
1608 Entity.setDiag(PDiag); // TODO: avoid copy in CheckDestructorAccess()
1610 return CheckAccess(*this, Loc, Entity); in CheckDestructorAccess()
1617 const InitializedEntity &Entity, in CheckConstructorAccess() argument
1623 switch (Entity.getKind()) { in CheckConstructorAccess()
1633 PD << Entity.isInheritedVirtualBase() in CheckConstructorAccess()
1634 << Entity.getBaseSpecifier()->getType() << getSpecialMember(Constructor); in CheckConstructorAccess()
1638 const FieldDecl *Field = cast<FieldDecl>(Entity.getDecl()); in CheckConstructorAccess()
1645 StringRef VarName = Entity.getCapturedVarName(); in CheckConstructorAccess()
1647 PD << VarName << Entity.getType() << getSpecialMember(Constructor); in CheckConstructorAccess()
1653 return CheckConstructorAccess(UseLoc, Constructor, Found, Entity, PD); in CheckConstructorAccess()
1660 const InitializedEntity &Entity, in CheckConstructorAccess() argument
1676 if ((Entity.getKind() == InitializedEntity::EK_Base || in CheckConstructorAccess()
1677 Entity.getKind() == InitializedEntity::EK_Delegating) && in CheckConstructorAccess()
1678 !Entity.getParent()) { in CheckConstructorAccess()
1709 AccessTarget Entity(Context, AccessTarget::Member, NamingClass, Found, in CheckAllocationAccess() local
1712 Entity.setDiag(diag::err_access) in CheckAllocationAccess()
1715 return CheckAccess(*this, OpLoc, Entity); in CheckAllocationAccess()
1727 AccessTarget Entity(Context, AccessTarget::Member, NamingClass, in CheckMemberAccess() local
1730 return CheckAccess(*this, UseLoc, Entity); in CheckMemberAccess()
1742 AccessTarget Entity(Context, AccessTarget::Member, DecomposedClass, Field, in CheckStructuredBindingMemberAccess() local
1744 Entity.setDiag(diag::err_decomp_decl_inaccessible_field); in CheckStructuredBindingMemberAccess()
1746 return CheckAccess(*this, UseLoc, Entity); in CheckStructuredBindingMemberAccess()
1762 AccessTarget Entity(Context, AccessTarget::Member, NamingClass, Found, in CheckMemberOperatorAccess() local
1764 Entity.setDiag(diag::err_access) in CheckMemberOperatorAccess()
1768 return CheckAccess(*this, OpLoc, Entity); in CheckMemberOperatorAccess()
1813 AccessTarget Entity(Context, AccessTarget::Member, NamingClass, Found, in CheckAddressOfMemberAccess() local
1815 Entity.setDiag(diag::err_access) in CheckAddressOfMemberAccess()
1818 return CheckAccess(*this, Ovl->getNameLoc(), Entity); in CheckAddressOfMemberAccess()
1844 AccessTarget Entity(Context, AccessTarget::Base, BaseD, DerivedD, in CheckBaseClassAccess() local
1847 Entity.setDiag(DiagID) << Derived << Base; in CheckBaseClassAccess()
1851 AccessLoc, Entity)) { in CheckBaseClassAccess()
1858 return CheckAccess(*this, AccessLoc, Entity); in CheckBaseClassAccess()
1869 AccessTarget Entity(Context, AccessedEntity::Member, in CheckLookupAccess() local
1872 Entity.setDiag(diag::err_access); in CheckLookupAccess()
1873 CheckAccess(*this, R.getNameLoc(), Entity); in CheckLookupAccess()
1905 AccessTarget Entity(Context, AccessedEntity::Member, NamingClass, in IsSimplyAccessible() local
1908 return ::IsAccessible(*this, EC, Entity) != ::AR_inaccessible; in IsSimplyAccessible()