Lines Matching defs:DECL
329 void Sema::AddAnyMethodToGlobalPool(Decl *D) {
332 // If we don't have a valid method decl, simply return.
362 void Sema::ActOnStartOfObjCMethodDef(Scope *FnBodyScope, Decl *D) {
369 // If we don't have a valid method decl, simply return.
384 // Create Decl objects for each parameter, entrring them in the scope for
584 // The previous declaration was not a class decl. Check if we have a
772 ArrayRef<Decl *> typeParamsIn,
974 Decl *Sema::ActOnStartClassInterface(
979 Decl *const *ProtoRefs, unsigned NumProtoRefs,
998 // A previous decl with a different name is because of
1004 // A lookup for 'OldImage' will return the 'NewImage' decl.
1109 void Sema::ActOnTypedefedProtocols(SmallVectorImpl<Decl *> &ProtocolRefs,
1136 Decl *Sema::ActOnCompatibilityAlias(SourceLocation AtLoc,
1211 Decl *Sema::ActOnStartProtocolInterface(
1213 SourceLocation ProtocolLoc, Decl *const *ProtoRefs, unsigned NumProtoRefs,
1235 // If we are using modules, add the decl to the context in order to
1300 SmallVectorImpl<Decl *> &Protocols) {
1322 // can set the objc decl as the availability context, otherwise check now.
1421 SmallVectorImpl<Decl *> &protocols,
1455 // can set the objc decl as the availability context, otherwise check now.
1480 if (auto *decl = LookupSingleName(S, identifiers[i], identifierLocs[i],
1482 if (isa<ObjCInterfaceDecl>(decl)) {
1485 } else if (!isa<TypeDecl>(decl)) {
1543 NamedDecl *decl = LookupSingleName(S, identifiers[i], identifierLocs[i],
1545 if (!decl) {
1550 if (auto typeDecl = dyn_cast<TypeDecl>(decl)) {
1556 if (auto objcClass = dyn_cast<ObjCInterfaceDecl>(decl)) {
1619 assert(numTypeDeclsResolved == identifiers.size() && "Unresolved type decl");
1777 SmallVector<Decl *, 8> DeclsInGroup;
1802 Decl *Sema::ActOnStartCategoryInterface(
1806 Decl *const *ProtoRefs, unsigned NumProtoRefs,
1819 // the enclosing method declarations. We mark the decl invalid
1898 Decl *Sema::ActOnStartCategoryImplementation(
1964 Decl *Sema::ActOnStartClassImplementation(
2031 // Build, chain & install the interface decl into the identifier.
2097 Sema::ActOnFinishObjCImplementation(Decl *ObjCImpDecl, ArrayRef<Decl *> Decls) {
2098 SmallVector<Decl *, 64> DeclsInGroup;
2102 Decl *Dcl = Decls[i];
2118 assert(ImpDecl && "missing implementation decl");
2122 /// Check case of non-existing \@interface decl.
2123 /// (legacy objective-c \@implementation decl without an \@interface decl).
2312 static bool objcModifiersConflict(Decl::ObjCDeclQualifier x,
2313 Decl::ObjCDeclQualifier y) {
2314 return (x & ~Decl::OBJC_TQ_CSNullability) !=
2315 (y & ~Decl::OBJC_TQ_CSNullability);
2353 ((MethodImpl->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability)
2357 ((MethodDecl->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability)
2439 ((ImplVar->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability)
2443 ((IfaceVar->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability)
2488 ObjCMethodDecl *decl) {
2490 ObjCMethodFamily declFamily = decl->getMethodFamily();
2499 if (impl->isInvalidDecl() || decl->isInvalidDecl()) return true;
2506 unmatched = decl;
2552 S.Diag(decl->getLocation(), noteID) << int(familySelector) << int(reasonSelector);
3051 SmallVector<Decl *, 8> DeclsInGroup;
3089 // A previous decl with a different name is because of
3095 // A lookup for 'OldImage' will return the 'NewImage' decl.
3422 if (cast<Decl>(Method->getDeclContext())->isInvalidDecl())
3807 case Decl::ObjCInterface:
3809 case Decl::ObjCProtocol:
3811 case Decl::ObjCCategory:
3815 case Decl::ObjCImplementation:
3817 case Decl::ObjCCategoryImpl:
3858 // Subsequent checks require interface decl.
3930 llvm::SmallVector<const Decl *, 4> DirectMembers;
3965 Decl *Sema::ActOnAtEnd(Scope *S, SourceRange AtEnd, ArrayRef<Decl *> allMethods,
3973 Decl *ClassDecl = OCD;
4168 // Find category interface decl and then check that all methods declared
4216 static Decl::ObjCDeclQualifier
4218 return (Decl::ObjCDeclQualifier) (unsigned) PQTVal;
4314 case Decl::type: \
4315 searchFrom(cast<type##Decl>(container)); \
4318 #define DECL(type, base) \
4319 case Decl::type:
4578 method->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability,
4581 prevMethod->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability);
4595 param->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability,
4597 prevParam->getObjCDeclQualifier() & Decl::OBJC_TQ_CSNullability);
4645 static void mergeObjCDirectMembers(Sema &S, Decl *CD, ObjCMethodDecl *Method) {
4701 Decl *Sema::ActOnMethodDeclaration(
4717 Decl *ClassDecl = cast<ObjCContainerDecl>(CurContext);
4893 int decl = 0, impl = 0;
4896 decl = Cat->IsClassExtension() ? 1 : 2;
4899 impl = 1 + (decl != 0);
4903 << decl << impl;
5060 bool Sema::CheckObjCDeclScope(Decl *D) {
5079 void Sema::ActOnDefs(Scope *S, Decl *TagD, SourceLocation DeclStart,
5081 SmallVectorImpl<Decl*> &Decls) {
5100 Decl *FD = ObjCAtDefsFieldDecl::Create(Context, Record,
5109 for (SmallVectorImpl<Decl*>::iterator D = Decls.begin();
5166 Decl *Sema::ActOnObjCExceptionDecl(Scope *S, Declarator &D) {