@@ -4689,15 +4689,15 @@ static void forAllLaterRedecls(DeclT *D, Fn F) {
46894689void ASTDeclReader::UpdateDecl (Decl *D) {
46904690 while (Record.getIdx () < Record.size ()) {
46914691 switch ((DeclUpdateKind)Record.readInt ()) {
4692- case UPD_CXX_ADDED_IMPLICIT_MEMBER : {
4692+ case DeclUpdateKind::CXXAddedImplicitMember : {
46934693 auto *RD = cast<CXXRecordDecl>(D);
46944694 Decl *MD = Record.readDecl ();
46954695 assert (MD && " couldn't read decl from update record" );
46964696 Reader.PendingAddedClassMembers .push_back ({RD, MD});
46974697 break ;
46984698 }
46994699
4700- case UPD_CXX_ADDED_ANONYMOUS_NAMESPACE : {
4700+ case DeclUpdateKind::CXXAddedAnonymousNamespace : {
47014701 auto *Anon = readDeclAs<NamespaceDecl>();
47024702
47034703 // Each module has its own anonymous namespace, which is disjoint from
@@ -4712,15 +4712,15 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
47124712 break ;
47134713 }
47144714
4715- case UPD_CXX_ADDED_VAR_DEFINITION : {
4715+ case DeclUpdateKind::CXXAddedVarDefinition : {
47164716 auto *VD = cast<VarDecl>(D);
47174717 VD->NonParmVarDeclBits .IsInline = Record.readInt ();
47184718 VD->NonParmVarDeclBits .IsInlineSpecified = Record.readInt ();
47194719 ReadVarDeclInit (VD);
47204720 break ;
47214721 }
47224722
4723- case UPD_CXX_POINT_OF_INSTANTIATION : {
4723+ case DeclUpdateKind::CXXPointOfInstantiation : {
47244724 SourceLocation POI = Record.readSourceLocation ();
47254725 if (auto *VTSD = dyn_cast<VarTemplateSpecializationDecl>(D)) {
47264726 VTSD->setPointOfInstantiation (POI);
@@ -4740,7 +4740,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
47404740 break ;
47414741 }
47424742
4743- case UPD_CXX_INSTANTIATED_DEFAULT_ARGUMENT : {
4743+ case DeclUpdateKind::CXXInstantiatedDefaultArgument : {
47444744 auto *Param = cast<ParmVarDecl>(D);
47454745
47464746 // We have to read the default argument regardless of whether we use it
@@ -4755,7 +4755,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
47554755 break ;
47564756 }
47574757
4758- case UPD_CXX_INSTANTIATED_DEFAULT_MEMBER_INITIALIZER : {
4758+ case DeclUpdateKind::CXXInstantiatedDefaultMemberInitializer : {
47594759 auto *FD = cast<FieldDecl>(D);
47604760 auto *DefaultInit = Record.readExpr ();
47614761
@@ -4772,7 +4772,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
47724772 break ;
47734773 }
47744774
4775- case UPD_CXX_ADDED_FUNCTION_DEFINITION : {
4775+ case DeclUpdateKind::CXXAddedFunctionDefinition : {
47764776 auto *FD = cast<FunctionDecl>(D);
47774777 if (Reader.PendingBodies [FD]) {
47784778 // FIXME: Maybe check for ODR violations.
@@ -4794,7 +4794,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
47944794 break ;
47954795 }
47964796
4797- case UPD_CXX_INSTANTIATED_CLASS_DEFINITION : {
4797+ case DeclUpdateKind::CXXInstantiatedClassDefinition : {
47984798 auto *RD = cast<CXXRecordDecl>(D);
47994799 auto *OldDD = RD->getCanonicalDecl ()->DefinitionData ;
48004800 bool HadRealDefinition =
@@ -4855,7 +4855,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
48554855 break ;
48564856 }
48574857
4858- case UPD_CXX_RESOLVED_DTOR_DELETE : {
4858+ case DeclUpdateKind::CXXResolvedDtorDelete : {
48594859 // Set the 'operator delete' directly to avoid emitting another update
48604860 // record.
48614861 auto *Del = readDeclAs<FunctionDecl>();
@@ -4869,7 +4869,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
48694869 break ;
48704870 }
48714871
4872- case UPD_CXX_RESOLVED_EXCEPTION_SPEC : {
4872+ case DeclUpdateKind::CXXResolvedExceptionSpec : {
48734873 SmallVector<QualType, 8 > ExceptionStorage;
48744874 auto ESI = Record.readExceptionSpecInfo (ExceptionStorage);
48754875
@@ -4891,35 +4891,35 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
48914891 break ;
48924892 }
48934893
4894- case UPD_CXX_DEDUCED_RETURN_TYPE : {
4894+ case DeclUpdateKind::CXXDeducedReturnType : {
48954895 auto *FD = cast<FunctionDecl>(D);
48964896 QualType DeducedResultType = Record.readType ();
48974897 Reader.PendingDeducedTypeUpdates .insert (
48984898 {FD->getCanonicalDecl (), DeducedResultType});
48994899 break ;
49004900 }
49014901
4902- case UPD_DECL_MARKED_USED :
4902+ case DeclUpdateKind::DeclMarkedUsed :
49034903 // Maintain AST consistency: any later redeclarations are used too.
49044904 D->markUsed (Reader.getContext ());
49054905 break ;
49064906
4907- case UPD_MANGLING_NUMBER :
4907+ case DeclUpdateKind::ManglingNumber :
49084908 Reader.getContext ().setManglingNumber (cast<NamedDecl>(D),
49094909 Record.readInt ());
49104910 break ;
49114911
4912- case UPD_STATIC_LOCAL_NUMBER :
4912+ case DeclUpdateKind::StaticLocalNumber :
49134913 Reader.getContext ().setStaticLocalNumber (cast<VarDecl>(D),
49144914 Record.readInt ());
49154915 break ;
49164916
4917- case UPD_DECL_MARKED_OPENMP_THREADPRIVATE :
4917+ case DeclUpdateKind::DeclMarkedOpenMPThreadPrivate :
49184918 D->addAttr (OMPThreadPrivateDeclAttr::CreateImplicit (Reader.getContext (),
49194919 readSourceRange ()));
49204920 break ;
49214921
4922- case UPD_DECL_MARKED_OPENMP_ALLOCATE : {
4922+ case DeclUpdateKind::DeclMarkedOpenMPAllocate : {
49234923 auto AllocatorKind =
49244924 static_cast <OMPAllocateDeclAttr::AllocatorTypeTy>(Record.readInt ());
49254925 Expr *Allocator = Record.readExpr ();
@@ -4930,7 +4930,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
49304930 break ;
49314931 }
49324932
4933- case UPD_DECL_EXPORTED : {
4933+ case DeclUpdateKind::DeclExported : {
49344934 unsigned SubmoduleID = readSubmoduleID ();
49354935 auto *Exported = cast<NamedDecl>(D);
49364936 Module *Owner = SubmoduleID ? Reader.getSubmodule (SubmoduleID) : nullptr ;
@@ -4939,7 +4939,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
49394939 break ;
49404940 }
49414941
4942- case UPD_DECL_MARKED_OPENMP_DECLARETARGET : {
4942+ case DeclUpdateKind::DeclMarkedOpenMPDeclareTarget : {
49434943 auto MapType = Record.readEnum <OMPDeclareTargetDeclAttr::MapTypeTy>();
49444944 auto DevType = Record.readEnum <OMPDeclareTargetDeclAttr::DevTypeTy>();
49454945 Expr *IndirectE = Record.readExpr ();
@@ -4951,7 +4951,7 @@ void ASTDeclReader::UpdateDecl(Decl *D) {
49514951 break ;
49524952 }
49534953
4954- case UPD_ADDED_ATTR_TO_RECORD :
4954+ case DeclUpdateKind::AddedAttrToRecord :
49554955 AttrVec Attrs;
49564956 Record.readAttributes (Attrs);
49574957 assert (Attrs.size () == 1 );
0 commit comments