Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Pass.hpp

    r0e42794 rd76c588  
    3333#include "AST/Visitor.hpp"
    3434
    35 #include "AST/SymbolTable.hpp"
     35#include "SymTab/Indexer.h"
    3636
    3737// Private prelude header, needed for some of the magic tricks this class pulls off
     
    6161//                          postvisit/postmutate teminates.
    6262// | WithVisitorRef       - provides an pointer to the templated visitor wrapper
    63 // | WithSymbolTable      - provides symbol table functionality
     63// | WithIndexer          - provides indexer functionality (i.e. up-to-date symbol table)
    6464//-------------------------------------------------------------------------------------------------
    6565template< typename pass_t >
     
    206206
    207207private:
    208         /// Internal RAII guard for symbol table features
    209         struct guard_symtab {
    210                 guard_symtab( Pass<pass_t> & pass ): pass( pass ) { __pass::symtab::enter(pass, 0); }
    211                 ~guard_symtab()                                   { __pass::symtab::leave(pass, 0); }
     208        /// Internal RAII guard for indexer features
     209        struct guard_indexer {
     210                guard_indexer( Pass<pass_t> & pass ): pass( pass ) { __pass::indexer::enter(pass, 0); }
     211                ~guard_indexer()                                   { __pass::indexer::leave(pass, 0); }
    212212                Pass<pass_t> & pass;
    213213        };
     
    294294};
    295295
    296 /// Use when the templated visitor should update the symbol table
    297 struct WithSymbolTable {
    298         SymbolTable symtab;
     296/// Use when the templated visitor should update the indexer
     297struct WithIndexer {
     298        SymTab::Indexer indexer;
    299299};
    300300}
Note: See TracChangeset for help on using the changeset viewer.