Changeset 68f9c43 for src/GenPoly/InstantiateGeneric.cc
- Timestamp:
- Mar 16, 2018, 5:15:02 PM (6 years ago)
- Branches:
- new-env, with_gc
- Children:
- 8d7bef2
- Parents:
- 6171841
- git-author:
- Aaron Moss <a3moss@…> (03/16/18 17:04:24)
- git-committer:
- Aaron Moss <a3moss@…> (03/16/18 17:15:02)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/GenPoly/InstantiateGeneric.cc
r6171841 r68f9c43 58 58 59 59 TypeList& operator= ( const TypeList &that ) { 60 deleteAll( params );61 62 60 params.clear(); 63 61 cloneAll( that.params, params ); … … 67 65 68 66 TypeList& operator= ( TypeList &&that ) { 69 deleteAll( params );70 71 67 params = std::move( that.params ); 72 68 … … 74 70 } 75 71 76 ~TypeList() { deleteAll( params );}72 ~TypeList() {} 77 73 78 74 bool operator== ( const TypeList& that ) const { … … 293 289 /// Strips the instances's type parameters 294 290 void stripInstParams( ReferenceToType *inst ) { 295 deleteAll( inst->get_parameters() );296 291 inst->get_parameters().clear(); 297 292 } … … 300 295 substituteMembers( base->get_members(), baseParams, typeSubs ); 301 296 302 // xxx - can't delete type parameters because they may have assertions that are used303 // deleteAll( baseParams );304 297 baseParams.clear(); 305 298 … … 380 373 newInst->set_baseStruct( concDecl ); 381 374 382 delete inst;383 375 inst = newInst; 384 376 break; … … 390 382 } 391 383 392 deleteAll( typeSubs );393 384 return inst; 394 385 } … … 430 421 newInst->set_baseUnion( concDecl ); 431 422 432 delete inst;433 423 inst = newInst; 434 424 break; … … 439 429 } 440 430 441 deleteAll( typeSubs );442 431 return inst; 443 432 } … … 477 466 ResolvExpr::adjustExprType( ret->result ); // pointer decay 478 467 std::swap( ret->env, memberExpr->env ); 479 delete memberExpr;480 468 return ret; 481 469 }
Note: See TracChangeset
for help on using the changeset viewer.