Index: src/ResolvExpr/AlternativeFinder.cc
===================================================================
--- src/ResolvExpr/AlternativeFinder.cc	(revision eddb39936d955da0421ebec4870c03688f9c4a46)
+++ src/ResolvExpr/AlternativeFinder.cc	(revision 54043f492a5390fd2baa5b5fafa932d524066315)
@@ -567,5 +567,5 @@
 				//if ( newNeedParents[ curDecl->get_uniqueId() ][ candDecl->get_uniqueId() ]++ > recursionParentLimit ) continue;
 
-				Expression *varExpr = data.combine( newerAlt.cost );
+				Expression *varExpr = data.combine( newerAlt.cvtCost );
 				delete varExpr->get_result();
 				varExpr->set_result( adjType->clone() );
@@ -1373,5 +1373,5 @@
 			Cost cost = Cost::zero;
 			Expression * newExpr = data.combine( cost );
-			alternatives.push_back( Alternative( newExpr, env, Cost::zero ) ); // xxx
+			alternatives.push_back( Alternative( newExpr, env, Cost::zero, cost ) );
 			PRINT(
 				std::cerr << "decl is ";
@@ -1488,5 +1488,5 @@
 				Cost cost = Cost::zero;
 				Expression * newExpr = data.combine( cost );
-				alternatives.push_back( Alternative( new AttrExpr( newExpr, argType->clone() ), env, cost ) );
+				alternatives.push_back( Alternative( new AttrExpr( newExpr, argType->clone() ), env, Cost::zero, cost ) );
 				for ( DeclarationWithType * retVal : function->returnVals ) {
 					alternatives.back().expr->result = retVal->get_type()->clone();
@@ -1527,5 +1527,5 @@
 				Cost cost = Cost::zero;
 				Expression * newExpr = data.combine( cost );
-				alternatives.push_back( Alternative( newExpr, env, cost ) );
+				alternatives.push_back( Alternative( newExpr, env, Cost::zero, cost ) );
 				renameTypes( alternatives.back().expr );
 			} // for
