Changeset cdb990a for src/SynTree


Ignore:
Timestamp:
May 18, 2018, 6:45:18 PM (7 years ago)
Author:
Rob Schluntz <rschlunt@…>
Branches:
ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, with_gc
Children:
ccdab45
Parents:
95642c9
git-author:
Rob Schluntz <rschlunt@…> (05/18/18 18:04:11)
git-committer:
Rob Schluntz <rschlunt@…> (05/18/18 18:45:18)
Message:

Strip redundant casts after every resolution

Location:
src/SynTree
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/SynTree/Expression.cc

    r95642c9 rcdb990a  
    5050}
    5151
     52void Expression::spliceInferParams( Expression * other ) {
     53        if ( ! other ) return;
     54        for ( auto p : other->inferParams ) {
     55                inferParams[p.first] = std::move( p.second );
     56        }
     57}
     58
    5259Expression::~Expression() {
    5360        delete env;
  • src/SynTree/Expression.h

    r95642c9 rcdb990a  
    7676        InferredParams & get_inferParams() { return inferParams; }
    7777
     78        // move other's inferParams to this
     79        void spliceInferParams( Expression * other );
     80
    7881        virtual Expression * clone() const override = 0;
    7982        virtual void accept( Visitor & v ) override = 0;
Note: See TracChangeset for help on using the changeset viewer.