Lines Matching refs:CSM

6732     CXXSpecialMember CSM = getSpecialMember(M);  in CheckCompletedCXXClass()  local
6734 if (CSM != CXXInvalid) { in CheckCompletedCXXClass()
6735 M->setTrivial(SpecialMemberIsTrivial(M, CSM)); in CheckCompletedCXXClass()
6740 SpecialMemberIsTrivial(M, CSM, TAH_ConsiderTrivialABI)); in CheckCompletedCXXClass()
6747 if ((CSM == CXXCopyConstructor || CSM == CXXMoveConstructor || in CheckCompletedCXXClass()
6748 CSM == CXXDestructor) && M->isUserProvided()) { in CheckCompletedCXXClass()
6757 (CSM == CXXDefaultConstructor || CSM == CXXCopyConstructor || in CheckCompletedCXXClass()
6758 CSM == CXXDestructor)) in CheckCompletedCXXClass()
6892 Sema &S, CXXRecordDecl *Class, Sema::CXXSpecialMember CSM, in lookupCallFromSpecialMember() argument
6895 if (CSM == Sema::CXXCopyAssignment || CSM == Sema::CXXMoveAssignment) in lookupCallFromSpecialMember()
6899 if (CSM == Sema::CXXDefaultConstructor || CSM == Sema::CXXDestructor) in lookupCallFromSpecialMember()
6904 return S.LookupSpecialMember(Class, CSM, in lookupCallFromSpecialMember()
6997 Sema::CXXSpecialMember CSM, unsigned Quals, in specialMemberIsConstexpr() argument
7004 assert(CSM == Sema::CXXDefaultConstructor); in specialMemberIsConstexpr()
7011 if (CSM == Sema::CXXDefaultConstructor) in specialMemberIsConstexpr()
7013 if (CSM == Sema::CXXDestructor) in specialMemberIsConstexpr()
7017 lookupCallFromSpecialMember(S, ClassDecl, CSM, Quals, ConstRHS); in specialMemberIsConstexpr()
7028 Sema &S, CXXRecordDecl *ClassDecl, Sema::CXXSpecialMember CSM, in defaultedSpecialMemberIsConstexpr() argument
7037 switch (CSM) { in defaultedSpecialMemberIsConstexpr()
7077 return CSM == Sema::CXXDefaultConstructor in defaultedSpecialMemberIsConstexpr()
7100 if (!specialMemberIsConstexpr(S, BaseClassDecl, CSM, 0, ConstArg, in defaultedSpecialMemberIsConstexpr()
7115 if (CSM == Sema::CXXDefaultConstructor && F->hasInClassInitializer()) in defaultedSpecialMemberIsConstexpr()
7120 if (!specialMemberIsConstexpr(S, FieldRecDecl, CSM, in defaultedSpecialMemberIsConstexpr()
7124 } else if (CSM == Sema::CXXDefaultConstructor) { in defaultedSpecialMemberIsConstexpr()
7155 Sema &S, SourceLocation Loc, CXXMethodDecl *MD, Sema::CXXSpecialMember CSM,
7228 CXXSpecialMember CSM) { in CheckExplicitlyDefaultedSpecialMember() argument
7231 assert(MD->isExplicitlyDefaulted() && CSM != CXXInvalid && in CheckExplicitlyDefaultedSpecialMember()
7257 if (CSM == CXXDefaultConstructor || CSM == CXXDestructor) in CheckExplicitlyDefaultedSpecialMember()
7264 << CSM << MD->getSourceRange(); in CheckExplicitlyDefaultedSpecialMember()
7271 << CSM << MD->getSourceRange(); in CheckExplicitlyDefaultedSpecialMember()
7279 if (CSM == CXXCopyConstructor) in CheckExplicitlyDefaultedSpecialMember()
7281 else if (CSM == CXXCopyAssignment) in CheckExplicitlyDefaultedSpecialMember()
7285 if (CSM == CXXCopyAssignment || CSM == CXXMoveAssignment) { in CheckExplicitlyDefaultedSpecialMember()
7295 << (CSM == CXXMoveAssignment) << ExpectedReturnType; in CheckExplicitlyDefaultedSpecialMember()
7305 << (CSM == CXXMoveAssignment) << getLangOpts().CPlusPlus14; in CheckExplicitlyDefaultedSpecialMember()
7324 diag::err_defaulted_special_member_volatile_param) << CSM; in CheckExplicitlyDefaultedSpecialMember()
7332 else if (CSM == CXXCopyConstructor || CSM == CXXCopyAssignment) { in CheckExplicitlyDefaultedSpecialMember()
7335 << (CSM == CXXCopyAssignment); in CheckExplicitlyDefaultedSpecialMember()
7341 << (CSM == CXXMoveAssignment); in CheckExplicitlyDefaultedSpecialMember()
7348 assert(CSM == CXXCopyAssignment && "unexpected non-ref argument"); in CheckExplicitlyDefaultedSpecialMember()
7362 bool Constexpr = defaultedSpecialMemberIsConstexpr(*this, RD, CSM, in CheckExplicitlyDefaultedSpecialMember()
7372 << CSM; in CheckExplicitlyDefaultedSpecialMember()
7402 if (ShouldDeleteForTypeMismatch || ShouldDeleteSpecialMember(MD, CSM)) { in CheckExplicitlyDefaultedSpecialMember()
7406 Diag(MD->getLocation(), diag::warn_defaulted_method_deleted) << CSM; in CheckExplicitlyDefaultedSpecialMember()
7408 Diag(MD->getLocation(), diag::note_deleted_type_mismatch) << CSM; in CheckExplicitlyDefaultedSpecialMember()
7410 ShouldDeleteSpecialMember(MD, CSM, nullptr, /*Diagnose*/true); in CheckExplicitlyDefaultedSpecialMember()
7415 diag::warn_cxx17_compat_defaulted_method_type_mismatch) << CSM; in CheckExplicitlyDefaultedSpecialMember()
7421 Diag(MD->getLocation(), diag::err_out_of_line_default_deletes) << CSM; in CheckExplicitlyDefaultedSpecialMember()
7423 ShouldDeleteSpecialMember(MD, CSM, nullptr, /*Diagnose*/true); in CheckExplicitlyDefaultedSpecialMember()
8613 Sema::CXXSpecialMember CSM; member
8619 SpecialMemberVisitor(Sema &S, CXXMethodDecl *MD, Sema::CXXSpecialMember CSM, in SpecialMemberVisitor()
8621 : S(S), MD(MD), CSM(CSM), ICI(ICI) { in SpecialMemberVisitor()
8622 switch (CSM) { in SpecialMemberVisitor()
8649 return CSM == Sema::CXXMoveConstructor || CSM == Sema::CXXMoveAssignment; in isMove()
8655 return lookupCallFromSpecialMember(S, Class, CSM, Quals, in lookupIn()
8664 assert(CSM == Sema::CXXDefaultConstructor); in lookupInheritedCtor()
8734 Sema::CXXSpecialMember CSM, in SpecialMemberDeletionInfo()
8736 : SpecialMemberVisitor(S, MD, CSM, ICI), Diagnose(Diagnose), in SpecialMemberDeletionInfo()
8742 return ICI ? Sema::CXXInvalid : CSM; in getEffectiveCSM()
8858 if (!(CSM == Sema::CXXDefaultConstructor && in shouldDeleteForClassSubobject()
8888 if (CSM == Sema::CXXDefaultConstructor && FD->hasInClassInitializer()) in shouldDeleteForVariantObjCPtrMember()
8940 if (CSM == Sema::CXXDefaultConstructor) { in shouldDeleteForField()
8964 } else if (CSM == Sema::CXXCopyConstructor) { in shouldDeleteForField()
9015 if (CSM == Sema::CXXDefaultConstructor && AllVariantFieldsAreConst && in shouldDeleteForField()
9043 if (CSM == Sema::CXXDefaultConstructor && inUnion() && AllFieldsAreConst) { in shouldDeleteForAllConstMembers()
9062 bool Sema::ShouldDeleteSpecialMember(CXXMethodDecl *MD, CXXSpecialMember CSM, in ShouldDeleteSpecialMember() argument
9078 (CSM == CXXDefaultConstructor || CSM == CXXCopyAssignment)) { in ShouldDeleteSpecialMember()
9087 if (CSM != CXXDefaultConstructor && CSM != CXXDestructor && in ShouldDeleteSpecialMember()
9096 (CSM == CXXCopyConstructor || CSM == CXXCopyAssignment)) { in ShouldDeleteSpecialMember()
9107 (!DeletesOnlyMatchingCopy || CSM == CXXCopyConstructor)) { in ShouldDeleteSpecialMember()
9119 (!DeletesOnlyMatchingCopy || CSM == CXXCopyAssignment)) { in ShouldDeleteSpecialMember()
9135 << (CSM == CXXCopyAssignment) << RD in ShouldDeleteSpecialMember()
9147 if (CSM == CXXDestructor && MD->isVirtual()) { in ShouldDeleteSpecialMember()
9159 SpecialMemberDeletionInfo SMI(*this, MD, CSM, ICI, Diagnose); in ShouldDeleteSpecialMember()
9181 assert(ICI || CSM == getSpecialMember(MD)); in ShouldDeleteSpecialMember()
9182 auto RealCSM = CSM; in ShouldDeleteSpecialMember()
9221 Sema::CXXSpecialMember CSM, unsigned Quals, in findTrivialSpecialMember() argument
9228 switch (CSM) { in findTrivialSpecialMember()
9318 lookupCallFromSpecialMember(S, RD, CSM, Quals, ConstRHS); in findTrivialSpecialMember()
9339 (CSM == Sema::CXXCopyConstructor || CSM == Sema::CXXMoveConstructor)) in findTrivialSpecialMember()
9377 Sema::CXXSpecialMember CSM, in checkTrivialSubobjectCall() argument
9385 if (findTrivialSpecialMember(S, SubRD, CSM, SubType.getCVRQualifiers(), in checkTrivialSubobjectCall()
9393 if (!Selected && CSM == Sema::CXXDefaultConstructor) { in checkTrivialSubobjectCall()
9400 << Kind << SubType.getUnqualifiedType() << CSM << SubType; in checkTrivialSubobjectCall()
9404 << Kind << SubType.getUnqualifiedType() << CSM; in checkTrivialSubobjectCall()
9407 << Kind << SubType.getUnqualifiedType() << CSM; in checkTrivialSubobjectCall()
9413 << Kind << SubType.getUnqualifiedType() << CSM; in checkTrivialSubobjectCall()
9416 S.SpecialMemberIsTrivial(Selected, CSM, Sema::TAH_IgnoreTrivialABI, in checkTrivialSubobjectCall()
9427 Sema::CXXSpecialMember CSM, in checkTrivialClassMembers() argument
9440 CSM, ConstArg, TAH, Diagnose)) in checkTrivialClassMembers()
9449 if (CSM == Sema::CXXDefaultConstructor && FI->hasInClassInitializer()) { in checkTrivialClassMembers()
9469 CSM, TSK_Field, TAH, Diagnose)) in checkTrivialClassMembers()
9478 void Sema::DiagnoseNontrivial(const CXXRecordDecl *RD, CXXSpecialMember CSM) { in DiagnoseNontrivial() argument
9481 bool ConstArg = (CSM == CXXCopyConstructor || CSM == CXXCopyAssignment); in DiagnoseNontrivial()
9482 checkTrivialSubobjectCall(*this, RD->getLocation(), Ty, ConstArg, CSM, in DiagnoseNontrivial()
9490 bool Sema::SpecialMemberIsTrivial(CXXMethodDecl *MD, CXXSpecialMember CSM, in SpecialMemberIsTrivial() argument
9492 assert(!MD->isUserProvided() && CSM != CXXInvalid && "not special enough"); in SpecialMemberIsTrivial()
9501 switch (CSM) { in SpecialMemberIsTrivial()
9568 ConstArg, CSM, TSK_BaseClass, TAH, Diagnose)) in SpecialMemberIsTrivial()
9583 if (!checkTrivialClassMembers(*this, RD, CSM, ConstArg, TAH, Diagnose)) in SpecialMemberIsTrivial()
9589 if (CSM == CXXDestructor && MD->isVirtual()) { in SpecialMemberIsTrivial()
9598 if (CSM != CXXDestructor && MD->getParent()->isDynamicClass()) { in SpecialMemberIsTrivial()
12749 Sema::CXXSpecialMember CSM, in SpecialMemberExceptionSpecInfo()
12752 : SpecialMemberVisitor(S, MD, CSM, ICI), Loc(Loc), ExceptSpec(S) {} in SpecialMemberExceptionSpecInfo()
12782 if (CSM == Sema::CXXDefaultConstructor && FD->hasInClassInitializer()) { in visitField()
12841 Sema &S, SourceLocation Loc, CXXMethodDecl *MD, Sema::CXXSpecialMember CSM, in ComputeDefaultedSpecialMemberExceptionSpec() argument
12850 SpecialMemberExceptionSpecInfo Info(S, MD, CSM, ICI, MD->getLocation()); in ComputeDefaultedSpecialMemberExceptionSpec()
12891 DeclaringSpecialMember(Sema &S, CXXRecordDecl *RD, Sema::CXXSpecialMember CSM) in DeclaringSpecialMember()
12892 : S(S), D(RD, CSM), SavedContext(S, RD) { in DeclaringSpecialMember()
12911 Ctx.SpecialMember = CSM; in DeclaringSpecialMember()