Ignore:
Timestamp:
Mar 16, 2018, 5:15:02 PM (6 years ago)
Author:
Aaron Moss <a3moss@…>
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)
Message:

First pass at delete removal

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/GenPoly/InstantiateGeneric.cc

    r6171841 r68f9c43  
    5858
    5959                TypeList& operator= ( const TypeList &that ) {
    60                         deleteAll( params );
    61 
    6260                        params.clear();
    6361                        cloneAll( that.params, params );
     
    6765
    6866                TypeList& operator= ( TypeList &&that ) {
    69                         deleteAll( params );
    70 
    7167                        params = std::move( that.params );
    7268
     
    7470                }
    7571
    76                 ~TypeList() { deleteAll( params ); }
     72                ~TypeList() {}
    7773
    7874                bool operator== ( const TypeList& that ) const {
     
    293289        /// Strips the instances's type parameters
    294290        void stripInstParams( ReferenceToType *inst ) {
    295                 deleteAll( inst->get_parameters() );
    296291                inst->get_parameters().clear();
    297292        }
     
    300295                substituteMembers( base->get_members(), baseParams, typeSubs );
    301296
    302                 // xxx - can't delete type parameters because they may have assertions that are used
    303                 // deleteAll( baseParams );
    304297                baseParams.clear();
    305298
     
    380373                        newInst->set_baseStruct( concDecl );
    381374
    382                         delete inst;
    383375                        inst = newInst;
    384376                        break;
     
    390382                }
    391383
    392                 deleteAll( typeSubs );
    393384                return inst;
    394385        }
     
    430421                        newInst->set_baseUnion( concDecl );
    431422
    432                         delete inst;
    433423                        inst = newInst;
    434424                        break;
     
    439429                }
    440430
    441                 deleteAll( typeSubs );
    442431                return inst;
    443432        }
     
    477466                        ResolvExpr::adjustExprType( ret->result ); // pointer decay
    478467                        std::swap( ret->env, memberExpr->env );
    479                         delete memberExpr;
    480468                        return ret;
    481469                }
Note: See TracChangeset for help on using the changeset viewer.