Skip to content

Commit de62923

Browse files
committed
---
yaml --- r: 58039 b: refs/heads/auto c: 76f7207 h: refs/heads/master i: 58037: e357be6 58035: 5172cff 58031: 0cdfcd2 v: v3
1 parent a8da730 commit de62923

File tree

4 files changed

+22
-3
lines changed

4 files changed

+22
-3
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0
1414
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
1515
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1616
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
17-
refs/heads/auto: 87c46b548a5c9d3183a7d76db8c2e0660f917130
17+
refs/heads/auto: 76f7207af22d1c64280b1dcbf7d99d198781e0b2
1818
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
1919
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c

branches/auto/src/librustc/middle/ty.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1253,6 +1253,16 @@ pub fn mk_opaque_closure_ptr(cx: ctxt, sigil: ast::Sigil) -> t {
12531253

12541254
pub fn mk_opaque_box(cx: ctxt) -> t { mk_t(cx, ty_opaque_box) }
12551255

1256+
// Converts s to its machine type equivalent
1257+
pub fn mach_sty(cfg: @session::config, t: t) -> sty {
1258+
match get(t).sty {
1259+
ty_int(ast::ty_i) => ty_int(cfg.int_type),
1260+
ty_uint(ast::ty_u) => ty_uint(cfg.uint_type),
1261+
ty_float(ast::ty_f) => ty_float(cfg.float_type),
1262+
ref s => (/*bad*/copy *s)
1263+
}
1264+
}
1265+
12561266
pub fn walk_ty(ty: t, f: &fn(t)) {
12571267
maybe_walk_ty(ty, |t| { f(t); true });
12581268
}

branches/auto/src/librustc/middle/typeck/infer/combine.rs

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -480,8 +480,6 @@ pub fn super_tys<C:Combine>(
480480
unify_float_variable(self, !self.a_is_expected(), v_id, v)
481481
}
482482

483-
(ty::ty_nil, _) |
484-
(ty::ty_bool, _) |
485483
(ty::ty_int(_), _) |
486484
(ty::ty_uint(_), _) |
487485
(ty::ty_float(_), _) => {
@@ -492,6 +490,16 @@ pub fn super_tys<C:Combine>(
492490
}
493491
}
494492

493+
(ty::ty_nil, _) |
494+
(ty::ty_bool, _) => {
495+
let cfg = tcx.sess.targ_cfg;
496+
if ty::mach_sty(cfg, a) == ty::mach_sty(cfg, b) {
497+
Ok(a)
498+
} else {
499+
Err(ty::terr_sorts(expected_found(self, a, b)))
500+
}
501+
}
502+
495503
(ty::ty_param(ref a_p), ty::ty_param(ref b_p)) if a_p.idx == b_p.idx => {
496504
Ok(a)
497505
}

branches/auto/src/libstd/flatpipes.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -678,6 +678,7 @@ mod test {
678678
}
679679
680680
#[test]
681+
#[ignore(reason = "FIXME #6211 failing on linux snapshot machine")]
681682
fn test_serializing_pipes() {
682683
let (port, chan) = serial::pipe_stream();
683684

0 commit comments

Comments
 (0)