Changes in src/AST/Pass.proto.hpp [4ec9513:eb211bf]
- File:
-
- 1 edited
-
src/AST/Pass.proto.hpp (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/AST/Pass.proto.hpp
r4ec9513 reb211bf 26 26 27 27 struct PureVisitor; 28 29 template<typename node_t>30 node_t * deepCopy( const node_t * localRoot );31 28 32 29 namespace __pass { … … 399 396 static inline auto addStructFwd( core_t & core, int, const ast::StructDecl * decl ) -> decltype( core.symtab.addStruct( decl ), void() ) { 400 397 ast::StructDecl * fwd = new ast::StructDecl( decl->location, decl->name ); 401 for ( const auto & param : decl->params ) { 402 fwd->params.push_back( deepCopy( param.get() ) ); 403 } 398 fwd->params = decl->params; 404 399 core.symtab.addStruct( fwd ); 405 400 } … … 410 405 template<typename core_t> 411 406 static inline auto addUnionFwd( core_t & core, int, const ast::UnionDecl * decl ) -> decltype( core.symtab.addUnion( decl ), void() ) { 412 ast::UnionDecl * fwd = new ast::UnionDecl( decl->location, decl->name ); 413 for ( const auto & param : decl->params ) { 414 fwd->params.push_back( deepCopy( param.get() ) ); 415 } 407 UnionDecl * fwd = new UnionDecl( decl->location, decl->name ); 408 fwd->params = decl->params; 416 409 core.symtab.addUnion( fwd ); 417 410 }
Note:
See TracChangeset
for help on using the changeset viewer.