Skip to content

Commit 82bc1f6

Browse files
committed
---
yaml --- r: 2999 b: refs/heads/master c: 3009574 h: refs/heads/master i: 2997: 264fa0f 2995: 533ab8b 2991: c690f9c v: v3
1 parent de54e8b commit 82bc1f6

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
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: 3c1be2aeba334f260ebb23d885af1242f5fd52f1
2+
refs/heads/master: 3009574165ca607d1d12bd9a557f06776f69927a

trunk/src/comp/middle/ty.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1810,9 +1810,10 @@ mod unify {
18101810

18111811
fn record_var_binding(&@ctxt cx, int key, t typ) -> result {
18121812
ufind::grow(cx.vb.sets, (key as uint) + 1u);
1813+
auto root = ufind::find(cx.vb.sets, key as uint);
18131814

18141815
auto result_type = typ;
1815-
alt (smallintmap::find[t](cx.vb.types, key as uint)) {
1816+
alt (smallintmap::find[t](cx.vb.types, root)) {
18161817
case (some(?old_type)) {
18171818
alt (unify_step(cx, old_type, typ)) {
18181819
case (ures_ok(?unified_type)) {
@@ -1824,7 +1825,7 @@ mod unify {
18241825
case (none) { /* fall through */ }
18251826
}
18261827

1827-
smallintmap::insert[t](cx.vb.types, key as uint, result_type);
1828+
smallintmap::insert[t](cx.vb.types, root, result_type);
18281829
ret ures_ok(typ);
18291830
}
18301831

0 commit comments

Comments
 (0)