Changeset 8b11840 for src/InitTweak
- Timestamp:
- Sep 22, 2017, 1:50:00 PM (7 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- b56c17c
- Parents:
- 05807e9
- Location:
- src/InitTweak
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/InitTweak/GenInit.cc
r05807e9 r8b11840 115 115 116 116 void genInit( std::list< Declaration * > & translationUnit ) { 117 ReturnFixer::makeReturnTemp( translationUnit );117 fixReturnStatements( translationUnit ); 118 118 HoistArrayDimension::hoistArrayDimension( translationUnit ); 119 119 CtorDtor::generateCtorDtor( translationUnit ); 120 120 } 121 121 122 void ReturnFixer::makeReturnTemp( std::list< Declaration * > & translationUnit ) {122 void fixReturnStatements( std::list< Declaration * > & translationUnit ) { 123 123 PassVisitor<ReturnFixer> fixer; 124 124 mutateAll( translationUnit, fixer ); -
src/InitTweak/GenInit.h
r05807e9 r8b11840 25 25 void genInit( std::list< Declaration * > & translationUnit ); 26 26 27 /// generates a single ctor/dtor statement using objDecl as the 'this' parameter and arg as the optional argument 28 ImplicitCtorDtorStmt * genCtorDtor( const std::string & fname, ObjectDecl * objDecl, Expression * arg = nullptr ); 27 /// Converts return statements into copy constructor calls on the hidden return variable 28 void fixReturnStatements( std::list< Declaration * > & translationUnit ); 29 30 /// generates a single ctor/dtor statement using objDecl as the 'this' parameter and arg as the optional argument 31 ImplicitCtorDtorStmt * genCtorDtor( const std::string & fname, ObjectDecl * objDecl, Expression * arg = nullptr ); 29 32 30 33 /// creates an appropriate ConstructorInit node which contains a constructor, destructor, and C-initializer
Note: See TracChangeset
for help on using the changeset viewer.