Changeset 71f4e4f for src/SynTree/Initializer.cc
- Timestamp:
- Jan 13, 2016, 5:19:47 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, with_gc
- Children:
- f1e012b
- Parents:
- 02c7d04
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/SynTree/Initializer.cc
r02c7d04 r71f4e4f 10 10 // Created On : Mon May 18 07:44:20 2015 11 11 // Last Modified By : Rob Schluntz 12 // Last Modified On : Thu Jan 07 15:00:18201613 // Update Count : 2 312 // Last Modified On : Wed Jan 13 15:31:45 2016 13 // Update Count : 28 14 14 // 15 15 … … 79 79 (*i)->print( os, indent + 2 ); 80 80 } 81 82 83 ConstructorInit::ConstructorInit( Expression * ctor, Initializer * init ) : Initializer( true ), ctor( ctor ), init( init ) {} 84 ConstructorInit::~ConstructorInit() { 85 delete ctor; 86 delete init; 87 } 88 89 ConstructorInit *ConstructorInit::clone() const { 90 return new ConstructorInit( *this ); 91 } 92 93 void ConstructorInit::print( std::ostream &os, int indent ) { 94 os << std::endl << std::string(indent, ' ') << "Constructor initializer: "; 95 if ( ctor ) { 96 os << " initially constructed with "; 97 ctor->print( os, indent+2 ); 98 } // if 99 100 if ( init ) { 101 os << " with fallback C-style initializer: "; 102 init->print( os, indent+2 ); 103 } 104 } 105 106 81 107 // Local Variables: // 82 108 // tab-width: 4 //
Note: See TracChangeset
for help on using the changeset viewer.