Skip to content

Commit 75aaace

Browse files
committed
---
yaml --- r: 2105 b: refs/heads/master c: 35e021e h: refs/heads/master i: 2103: 7550667 v: v3
1 parent e5b05a7 commit 75aaace

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: fee88f79f5d78de8bbebec6cfc4b04335fb597b6
2+
refs/heads/master: 35e021ed53d3ab9e63686ec7d79bc3ca2af0c820

trunk/src/comp/middle/typeck.rs

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -858,6 +858,15 @@ mod Unify {
858858
}
859859
}
860860
}
861+
862+
// TODO: "freeze"
863+
let vec[@ty.t] param_substs_1 = vec();
864+
for (@ty.t subst in param_substs) {
865+
param_substs_1 += vec(subst);
866+
}
867+
868+
unified_type =
869+
ty.substitute_type_params(param_substs_1, unified_type);
861870
fcx.locals.insert(id, unified_type);
862871
}
863872
fn record_param(uint index, @ty.t binding) -> ty.unify_result {
@@ -1617,7 +1626,8 @@ fn check_pat(&@fn_ctxt fcx, @ast.pat pat) -> @ast.pat {
16171626
}
16181627

16191628
fn check_expr(&@fn_ctxt fcx, @ast.expr expr) -> @ast.expr {
1620-
// log "typechecking expr " + pretty.pprust.expr_to_str(expr);
1629+
//fcx.ccx.sess.span_warn(expr.span, "typechecking expr " +
1630+
// pretty.pprust.expr_to_str(expr));
16211631

16221632
// A generic function to factor out common logic from call and bind
16231633
// expressions.

0 commit comments

Comments
 (0)