Ignore:
Timestamp:
Aug 20, 2016, 5:33:07 AM (9 years ago)
Author:
Aaron Moss <bruceiv@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, ctor, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, memory, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
Children:
80722d0
Parents:
7b1bfc5 (diff), 2037f82 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of plg2.cs.uwaterloo.ca:software/cfa/cfa-cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Parser/ParseNode.cc

    r7b1bfc5 r4a7d895  
    1010// Created On       : Sat May 16 13:26:29 2015
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Mon Aug 15 14:49:06 2016
    13 // Update Count     : 99
     12// Last Modified On : Wed Aug 17 23:14:16 2016
     13// Update Count     : 126
    1414//
    1515
     
    1717using namespace std;
    1818
    19 // Builder
    2019int ParseNode::indent_by = 4;
    21 
    22 ParseNode::ParseNode() : next( 0 ) {};
    23 ParseNode::ParseNode( const string *name ) : name( *name ), next( 0 ) { delete name; }
    24 ParseNode::ParseNode( const string &name ) : name( name ), next( 0 ) { }
    25 
    26 ParseNode::~ParseNode() {
    27         delete next;
    28 };
    29 
    30 ParseNode *ParseNode::get_last() {
    31         ParseNode *current = this;
    32 
    33         while ( current->get_next() != 0 )
    34         current = current->get_next();
    35         return current;
    36 }
    37 
    38 ParseNode *ParseNode::set_last( ParseNode *next_ ) {
    39         if ( next_ != 0 ) get_last()->next = next_;
    40         return this;
    41 }
    42 
    43 void ParseNode::print( std::ostream &os, int indent ) const {}
    44 
    45 
    46 void ParseNode::printList( std::ostream &os, int indent ) const {
    47         print( os, indent );
    48 
    49         if ( next ) {
    50                 next->printList( os, indent );
    51         } // if
    52 }
    5320
    5421// Local Variables: //
Note: See TracChangeset for help on using the changeset viewer.