Changeset afcb0a3


Ignore:
Timestamp:
Jun 28, 2018, 3:27:02 PM (3 years ago)
Author:
Rob Schluntz <rschlunt@…>
Branches:
aaron-thesis, arm-eh, cleanup-dtors, deferred_resn, demangler, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer
Children:
69918cea
Parents:
48ed81c
Message:

Ignore QualifiedType? children in LinkReferenceToTypes?

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/SymTab/Validate.cc

    r48ed81c rafcb0a3  
    120120
    121121        /// Associates forward declarations of aggregates with their definitions
    122         struct LinkReferenceToTypes final : public WithIndexer, public WithGuards {
     122        struct LinkReferenceToTypes final : public WithIndexer, public WithGuards, public WithVisitorRef<LinkReferenceToTypes>, public WithShortCircuiting {
    123123                LinkReferenceToTypes( const Indexer *indexer );
    124124                void postvisit( TypeInstType *typeInst );
     
    128128                void postvisit( UnionInstType *unionInst );
    129129                void postvisit( TraitInstType *traitInst );
     130                void previsit( QualifiedType * qualType );
     131                void postvisit( QualifiedType * qualType );
    130132
    131133                void postvisit( EnumDecl *enumDecl );
     
    488490                } // if
    489491                checkGenericParameters( unionInst );
     492        }
     493
     494        void LinkReferenceToTypes::previsit( QualifiedType * ) {
     495                visit_children = false;
     496        }
     497
     498        void LinkReferenceToTypes::postvisit( QualifiedType * qualType ) {
     499                // linking only makes sense for the 'oldest ancestor' of the qualified type
     500                qualType->parent->accept( *visitor );
    490501        }
    491502
Note: See TracChangeset for help on using the changeset viewer.