Changeset 52c2a72 for src/SymTab/Indexer.h
- Timestamp:
- Mar 8, 2016, 4:28:40 PM (8 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, gc_noraii, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, string, with_gc
- Children:
- bed4c63e
- Parents:
- e8032b0
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/SymTab/Indexer.h
re8032b0 r52c2a72 90 90 void print( std::ostream &os, int indent = 0 ) const; 91 91 private: 92 // equivalents to lookup functions that only look at tables at scope `scope` (which should be >= tables->scope) 93 NamedTypeDecl *lookupTypeAtScope( const std::string &id, unsigned long scope ) const; 94 StructDecl *lookupStructAtScope( const std::string &id, unsigned long scope ) const; 95 EnumDecl *lookupEnumAtScope( const std::string &id, unsigned long scope ) const; 96 UnionDecl *lookupUnionAtScope( const std::string &id, unsigned long scope ) const; 97 TraitDecl *lookupTraitAtScope( const std::string &id, unsigned long scope ) const; 98 92 99 void addId( DeclarationWithType *decl ); 93 100 void addType( NamedTypeDecl *decl ); … … 100 107 101 108 struct Impl; 102 Impl *tables; ///< Copy-on-write instance of table data structure 103 bool doDebug; ///< Display debugging trace? 104 105 Indexer( Impl *_tables, bool _doDebug ) : tables( _tables ), doDebug( _doDebug ) {} 109 Impl *tables; ///< Copy-on-write instance of table data structure 110 unsigned long scope; ///< Scope index of this pointer 111 bool doDebug; ///< Display debugging trace? 106 112 107 113 /// Takes a new ref to a table (returns null if null) … … 110 116 static void deleteRef( Impl *toFree ); 111 117 112 /// Ensures that tables variable is writable (i.e. allocated and uniquely owned by this Indexer)118 /// Ensures that tables variable is writable (i.e. allocated, uniquely owned by this Indexer, and at the current scope) 113 119 void makeWritable(); 114 120 };
Note: See TracChangeset
for help on using the changeset viewer.