Lines Matching defs:Prop

108 CheckPropertyAgainstProtocol(Sema &S, ObjCPropertyDecl *Prop,
117 Prop->getIdentifier(), Prop->isInstanceProperty())) {
118 S.ObjC().DiagnosePropertyMismatch(Prop, ProtoProp, Proto->getIdentifier(),
125 CheckPropertyAgainstProtocol(S, Prop, P, Known);
851 for (const auto &Prop : llvm::enumerate(Properties)) {
853 if (Property->isReadOnly() && !Prop.value()->isReadOnly()) {
854 Property = Prop.value();
855 SelectedIndex = Prop.index();
875 const ObjCPropertyDecl *Prop;
880 for (ObjCPropertyDecl *Prop : Properties) {
882 unsigned Attr = Prop->getPropertyAttributesAsWritten();
887 Mismatches.push_back({Prop, Kind, AttributeName});
919 if (Property->getGetterName() != Prop->getGetterName()) {
920 Mismatches.push_back({Prop, DifferentGetter, ""});
923 if (!Property->isReadOnly() && !Prop->isReadOnly() &&
924 Property->getSetterName() != Prop->getSetterName()) {
925 Mismatches.push_back({Prop, DifferentSetter, ""});
928 QualType LHSType = S.Context.getCanonicalType(Prop->getType());
934 Mismatches.push_back({Prop, IncompatibleType, ""});
974 S.Diag(Note.Prop->getLocation(), diag::note_protocol_property_declare)
978 Diag << Note.Prop->getType();
985 Diag << Note.Prop->getGetterName();
988 Diag << Note.Prop->getSetterName();
999 static bool hasWrittenStorageAttribute(ObjCPropertyDecl *Prop,
1001 if (Prop->getPropertyAttributesAsWritten() & OwnershipMask) return true;
1008 if (Prop->isReadOnly()) return false;
1011 auto Category = dyn_cast<ObjCCategoryDecl>(Prop->getDeclContext());
1016 for (auto *Found : OrigClass->lookup(Prop->getDeclName())) {
1024 Prop->getIdentifier(), QueryKind))
1740 for (auto *Prop : IDecl->properties()) {
1741 if (CollectClassPropsOnly && !Prop->isClassProperty())
1743 PropMap[std::make_pair(Prop->getIdentifier(), Prop->isClassProperty())] =
1744 Prop;
1760 for (auto *Prop : CATDecl->properties()) {
1761 if (CollectClassPropsOnly && !Prop->isClassProperty())
1763 PropMap[std::make_pair(Prop->getIdentifier(), Prop->isClassProperty())] =
1764 Prop;
1774 for (auto *Prop : PDecl->properties()) {
1775 if (CollectClassPropsOnly && !Prop->isClassProperty())
1778 SuperPropMap[std::make_pair(Prop->getIdentifier(),
1779 Prop->isClassProperty())];
1783 PropertyFromSuper->getIdentifier() != Prop->getIdentifier()) {
1785 PropMap[std::make_pair(Prop->getIdentifier(),
1786 Prop->isClassProperty())];
1788 PropEntry = Prop;
1844 ObjCPropertyDecl *Prop) {
1847 if (Prop->getPropertyAttributes() & ObjCPropertyAttribute::kind_readonly)
1852 if (!SuperClassImplementsGetter && SDecl->getInstanceMethod(Prop->getGetterName()))
1855 if (!SuperClassImplementsSetter && SDecl->getInstanceMethod(Prop->getSetterName()))
1878 ObjCPropertyDecl *Prop = PropEntry.second;
1880 if (Prop->isInvalidDecl() ||
1881 Prop->isClassProperty() ||
1882 Prop->getPropertyImplementation() == ObjCPropertyDecl::Optional)
1886 Prop->getIdentifier(), Prop->getQueryKind()))
1888 ObjCMethodDecl *ImpMethod = IMPDecl->getInstanceMethod(Prop->getGetterName());
1890 if (Prop->getPropertyAttributes() & ObjCPropertyAttribute::kind_readonly)
1892 ImpMethod = IMPDecl->getInstanceMethod(Prop->getSetterName());
1897 IMPDecl->FindPropertyImplIvarDecl(Prop->getIdentifier())) {
1898 Diag(Prop->getLocation(), diag::warn_no_autosynthesis_shared_ivar_property)
1899 << Prop->getIdentifier();
1905 SuperPropMap[std::make_pair(Prop->getIdentifier(),
1906 Prop->isClassProperty())];
1908 dyn_cast<ObjCProtocolDecl>(Prop->getDeclContext())) {
1913 if (!SuperClassImplementsProperty(IDecl, Prop) && !PropInSuperClass) {
1916 << Prop << Proto;
1917 Diag(Prop->getLocation(), diag::note_property_declare);
1919 (Twine("@synthesize ") + Prop->getName() + ";\n\n").str();
1927 if ((Prop->getPropertyAttributes() &
1931 !IMPDecl->getInstanceMethod(Prop->getSetterName()) &&
1932 !IDecl->HasUserDeclaredSetterMethod(Prop)) {
1933 Diag(Prop->getLocation(), diag::warn_no_autosynthesis_property)
1934 << Prop->getIdentifier();
1937 Diag(Prop->getLocation(), diag::warn_autosynthesis_property_in_superclass)
1938 << Prop->getIdentifier();
1951 /* property = */ Prop->getIdentifier(),
1952 /* ivar = */ Prop->getDefaultSynthIvarName(Context),
1953 Prop->getLocation(), Prop->getQueryKind()));
1954 if (PIDecl && !Prop->isUnavailable()) {
1955 Diag(Prop->getLocation(), diag::warn_missing_explicit_synthesis);
1977 ObjCPropertyDecl *Prop,
1983 x->isClassMethod() == Prop->isClassProperty();
1992 Prop->isClassProperty()))) {
1995 ? (Prop->isClassProperty()
1998 : (Prop->isClassProperty()
2001 S.Diag(IMPDecl->getLocation(), diag) << Prop->getDeclName() << Method;
2002 S.Diag(Prop->getLocation(), diag::note_property_declare);
2100 ObjCPropertyDecl *Prop = P->second;
2102 if (Prop->isInvalidDecl() ||
2103 Prop->getPropertyImplementation() == ObjCPropertyDecl::Optional ||
2104 PropImplMap.count(Prop) ||
2105 Prop->getAvailability() == AR_Unavailable)
2109 DiagnoseUnimplementedAccessor(SemaRef, PrimaryClass, Prop->getGetterName(),
2110 IMPDecl, CDecl, C, Prop, InsMap);
2111 if (!Prop->isReadOnly())
2113 Prop->getSetterName(), IMPDecl, CDecl, C,
2114 Prop, InsMap);
2150 for (auto *Prop : IDecl->properties())
2151 PM[std::make_pair(Prop->getIdentifier(), Prop->isClassProperty())] = Prop;
2153 for (auto *Prop : Ext->properties())
2154 PM[std::make_pair(Prop->getIdentifier(), Prop->isClassProperty())] = Prop;