Changeset 99da267 for src/AST/Copy.hpp
- Timestamp:
- Jul 19, 2019, 2:44:13 PM (4 years ago)
- Branches:
- ADT, arm-eh, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- f6cc734e
- Parents:
- 1f1c102
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/AST/Copy.hpp
r1f1c102 r99da267 23 23 24 24 template<typename node_t> 25 const node_t * shallowCopy( const node_t * node ) { 25 node_t * shallowCopy( const node_t * node ); 26 26 /* Create a shallow copy of the node given. 27 27 * … … 31 31 32 32 template<typename node_t> 33 node_t * deepCopy( node_t const * localRoot );33 node_t * deepCopy( const node_t * localRoot ); 34 34 /* Create a deep copy of the tree rooted at localRoot. 35 35 * … … 106 106 107 107 template<typename node_t> 108 node_t * shallowCopy( node_t const * localRoot ) {108 node_t * shallowCopy( const node_t * localRoot ) { 109 109 return localRoot->clone(); 110 110 } 111 111 112 112 template<typename node_t> 113 node_t * deepCopy( node_t const * localRoot ) {113 node_t * deepCopy( const node_t * localRoot ) { 114 114 Pass< DeepCopyCore > dc; 115 115 node_t const * newRoot = localRoot->accept( dc );
Note: See TracChangeset
for help on using the changeset viewer.