Changeset aeb8f70 for src/ResolvExpr


Ignore:
Timestamp:
Jan 10, 2019, 2:22:29 PM (6 years ago)
Author:
Aaron Moss <a3moss@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, no_list, persistent-indexer, pthread-emulation, qualifiedEnum
Children:
e99e43f
Parents:
73ac10e
git-author:
Aaron Moss <a3moss@…> (01/09/19 16:07:05)
git-committer:
Aaron Moss <a3moss@…> (01/10/19 14:22:29)
Message:

Fix memory leaks in assertion resolution

Location:
src/ResolvExpr
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/ResolvExpr/Alternative.cc

    r73ac10e raeb8f70  
    105105
    106106        Alternative::~Alternative() {
     107                for ( AssertionItem& n : need ) { delete n.decl; }
    107108                delete expr;
    108109        }
  • src/ResolvExpr/ResolveAssertions.cc

    r73ac10e raeb8f70  
    275275                                        std::move(newNeed), std::move(newOpenVars), crntResnSlot );
    276276                        } else {
    277                                 //delete adjType;
     277                                delete adjType;
    278278                        }
    279279                }
     
    396396                                                Cost resCost = coster.get( compat );
    397397                                                auto it = found.emplace( SymTab::Mangler::mangleType( resType ), resCost );
     398                                                delete resType;
    398399                                                if ( it.second == false && it.first->second < resCost ) continue;
    399400
Note: See TracChangeset for help on using the changeset viewer.