Lines Matching refs:Destructor
6754 bool Sema::CheckDestructor(CXXDestructorDecl *Destructor) { in CheckDestructor() argument
6755 CXXRecordDecl *RD = Destructor->getParent(); in CheckDestructor()
6757 if (!Destructor->getOperatorDelete() && Destructor->isVirtual()) { in CheckDestructor()
6760 if (!Destructor->isImplicit()) in CheckDestructor()
6761 Loc = Destructor->getLocation(); in CheckDestructor()
6778 Destructor->setOperatorDelete(OperatorDelete); in CheckDestructor()
9371 CXXDestructorDecl *Destructor in DeclareImplicitDestructor() local
9375 Destructor->setAccess(AS_public); in DeclareImplicitDestructor()
9376 Destructor->setDefaulted(); in DeclareImplicitDestructor()
9380 Destructor, in DeclareImplicitDestructor()
9386 FunctionProtoType::ExtProtoInfo EPI = getImplicitMethodEPI(*this, Destructor); in DeclareImplicitDestructor()
9387 Destructor->setType(Context.getFunctionType(Context.VoidTy, None, EPI)); in DeclareImplicitDestructor()
9389 AddOverriddenMethods(ClassDecl, Destructor); in DeclareImplicitDestructor()
9393 Destructor->setTrivial(ClassDecl->hasTrivialDestructor()); in DeclareImplicitDestructor()
9395 if (ShouldDeleteSpecialMember(Destructor, CXXDestructor)) in DeclareImplicitDestructor()
9396 SetDeclDeleted(Destructor, ClassLoc); in DeclareImplicitDestructor()
9403 PushOnScopeChains(Destructor, S, false); in DeclareImplicitDestructor()
9404 ClassDecl->addDecl(Destructor); in DeclareImplicitDestructor()
9406 return Destructor; in DeclareImplicitDestructor()
9410 CXXDestructorDecl *Destructor) { in DefineImplicitDestructor() argument
9411 assert((Destructor->isDefaulted() && in DefineImplicitDestructor()
9412 !Destructor->doesThisDeclarationHaveABody() && in DefineImplicitDestructor()
9413 !Destructor->isDeleted()) && in DefineImplicitDestructor()
9415 CXXRecordDecl *ClassDecl = Destructor->getParent(); in DefineImplicitDestructor()
9418 if (Destructor->isInvalidDecl()) in DefineImplicitDestructor()
9421 SynthesizedFunctionScope Scope(*this, Destructor); in DefineImplicitDestructor()
9424 MarkBaseAndMemberDestructorsReferenced(Destructor->getLocation(), in DefineImplicitDestructor()
9425 Destructor->getParent()); in DefineImplicitDestructor()
9427 if (CheckDestructor(Destructor) || Trap.hasErrorOccurred()) { in DefineImplicitDestructor()
9431 Destructor->setInvalidDecl(); in DefineImplicitDestructor()
9438 Destructor->getType()->castAs<FunctionProtoType>()); in DefineImplicitDestructor()
9440 SourceLocation Loc = Destructor->getLocEnd().isValid() in DefineImplicitDestructor()
9441 ? Destructor->getLocEnd() in DefineImplicitDestructor()
9442 : Destructor->getLocation(); in DefineImplicitDestructor()
9443 Destructor->setBody(new (Context) CompoundStmt(Loc)); in DefineImplicitDestructor()
9444 Destructor->markUsed(Context); in DefineImplicitDestructor()
9448 L->CompletedImplicitDefinition(Destructor); in DefineImplicitDestructor()
9514 CXXDestructorDecl *Destructor) { in AdjustDestructorExceptionSpec() argument
9522 const FunctionProtoType *DtorType = Destructor->getType()-> in AdjustDestructorExceptionSpec()
9532 EPI.ExceptionSpec.SourceDecl = Destructor; in AdjustDestructorExceptionSpec()
9533 Destructor->setType(Context.getFunctionType(Context.VoidTy, None, EPI)); in AdjustDestructorExceptionSpec()
11411 CXXDestructorDecl *Destructor = LookupDestructor(ClassDecl); in FinalizeVarWithDestructor() local
11412 MarkFunctionReferenced(VD->getLocation(), Destructor); in FinalizeVarWithDestructor()
11413 CheckDestructorAccess(VD->getLocation(), Destructor, in FinalizeVarWithDestructor()
11417 DiagnoseUseOfDecl(Destructor, VD->getLocation()); in FinalizeVarWithDestructor()
11419 if (Destructor->isTrivial()) return; in FinalizeVarWithDestructor()
13403 if (CXXDestructorDecl *Destructor = LookupDestructor(RD)) { in SetIvarInitializers() local
13404 MarkFunctionReferenced(Field->getLocation(), Destructor); in SetIvarInitializers()
13405 CheckDestructorAccess(Field->getLocation(), Destructor, in SetIvarInitializers()