Changeset 33a7b6d for src/ResolvExpr
- Timestamp:
- Nov 15, 2016, 5:30:52 PM (8 years ago)
- 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, resolv-new, with_gc
- Children:
- d9fa60a
- Parents:
- 8f9cc50
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/ResolvExpr/AlternativeFinder.cc
r8f9cc50 r33a7b6d 218 218 std::list< Declaration* > members; 219 219 aggInst->lookup( name, members ); 220 TypeSubstitution sub = TypeSubstitution( aggInst->get_baseParameters()->begin(), aggInst->get_baseParameters()->end(), aggInst->get_parameters().begin() ); 220 221 for ( std::list< Declaration* >::const_iterator i = members.begin(); i != members.end(); ++i ) { 221 222 if ( DeclarationWithType *dwt = dynamic_cast< DeclarationWithType* >( *i ) ) { 222 alternatives.push_back( Alternative( new MemberExpr( dwt, expr->clone() ), env, newCost ) ); 223 MemberExpr * memExpr = new MemberExpr( dwt, expr->clone() ); 224 sub.apply( memExpr ); 225 alternatives.push_back( Alternative( memExpr, env, newCost ) ); 223 226 renameTypes( alternatives.back().expr ); 224 227 } else { … … 800 803 AlternativeFinder funcFinder( indexer, env ); 801 804 funcFinder.findWithAdjustment( memberExpr->get_aggregate() ); 802 803 805 for ( AltList::const_iterator agg = funcFinder.alternatives.begin(); agg != funcFinder.alternatives.end(); ++agg ) { 804 806 if ( StructInstType *structInst = dynamic_cast< StructInstType* >( agg->expr->get_result() ) ) {
Note: See TracChangeset
for help on using the changeset viewer.