Ignore:
Timestamp:
May 11, 2015, 3:11:49 PM (9 years ago)
Author:
Rob Schluntz <rschlunt@…>
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:
b1a6d6b, c11e31c
Parents:
48e99f2
Message:

for loop initializers are hoisted properly and for loops a level of scope

File:
1 edited

Legend:

Unmodified
Added
Removed
  • translator/SymTab/Indexer.cc

    r48e99f2 rd4778a6  
    157157        leaveScope();
    158158    }
     159
     160    void Indexer::visit( ForStmt *forStmt ) {
     161        // for statements introduce a level of scope
     162        enterScope();
     163        Visitor::visit( forStmt );
     164        leaveScope();
     165    }
     166
    159167
    160168    void Indexer::lookupId( const std::string &id, std::list< DeclarationWithType* > &list ) const {
Note: See TracChangeset for help on using the changeset viewer.