Skip to content

Commit a534545

Browse files
committed
---
yaml --- r: 81294 b: refs/heads/snap-stage3 c: ebf5f40 h: refs/heads/master v: v3
1 parent c25b601 commit a534545

File tree

136 files changed

+183
-202
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

136 files changed

+183
-202
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: 4c6bf4872012c010f84dc7fa2cdfe87522533f89
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 630082ca8946ff2d0e814a73a2594ba65e1b29be
4+
refs/heads/snap-stage3: ebf5f406ef6e291655ec9eca5aa8bd95775cc67c
55
refs/heads/try: 70152ff55722878cde684ee6462c14c65f2c4729
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/src/test/compile-fail/assign-imm-local-twice.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
fn test() {
1212
let v: int;
1313
v = 1; //~ NOTE prior assignment occurs here
14-
info!("v=%d", v);
14+
info2!("v={}", v);
1515
v = 2; //~ ERROR re-assignment of immutable variable
16-
info!("v=%d", v);
16+
info2!("v={}", v);
1717
}
1818

1919
fn main() {

branches/snap-stage3/src/test/compile-fail/assign-to-method.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,5 @@ fn cat(in_x : uint, in_y : int) -> cat {
2727

2828
fn main() {
2929
let nyan : cat = cat(52u, 99);
30-
nyan.speak = || info!("meow"); //~ ERROR attempted to take value of method
30+
nyan.speak = || info2!("meow"); //~ ERROR attempted to take value of method
3131
}

branches/snap-stage3/src/test/compile-fail/autoderef-full-lval.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ fn main() {
2121
let a: clam = clam{x: @1, y: @2};
2222
let b: clam = clam{x: @10, y: @20};
2323
let z: int = a.x + b.y; //~ ERROR binary operation + cannot be applied to type `@int`
24-
info!(z);
24+
info2!("{:?}", z);
2525
assert_eq!(z, 21);
2626
let forty: fish = fish{a: @40};
2727
let two: fish = fish{a: @2};
2828
let answer: int = forty.a + two.a; //~ ERROR binary operation + cannot be applied to type `@int`
29-
info!(answer);
29+
info2!("{:?}", answer);
3030
assert_eq!(answer, 42);
3131
}

branches/snap-stage3/src/test/compile-fail/bad-bang-ann.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// Tests that a function with a ! annotation always actually fails
1313

1414
fn bad_bang(i: uint) -> ! {
15-
if i < 0u { } else { fail!(); }
15+
if i < 0u { } else { fail2!(); }
1616
//~^ ERROR expected `!` but found `()`
1717
}
1818

branches/snap-stage3/src/test/compile-fail/bad-const-type.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,4 @@
1111
// error-pattern:expected `~str` but found `int`
1212

1313
static i: ~str = 10i;
14-
fn main() { info!(i); }
14+
fn main() { info2!("{:?}", i); }

branches/snap-stage3/src/test/compile-fail/bind-by-move-neither-can-live-while-the-other-survives-1.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ struct X { x: () }
1212

1313
impl Drop for X {
1414
fn drop(&mut self) {
15-
error!("destructor runs");
15+
error2!("destructor runs");
1616
}
1717
}
1818

1919
fn main() {
2020
let x = Some(X { x: () });
2121
match x {
2222
Some(ref _y @ _z) => { }, //~ ERROR cannot bind by-move and by-ref in the same pattern
23-
None => fail!()
23+
None => fail2!()
2424
}
2525
}

branches/snap-stage3/src/test/compile-fail/bind-by-move-neither-can-live-while-the-other-survives-2.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ struct X { x: (), }
1212

1313
impl Drop for X {
1414
fn drop(&mut self) {
15-
error!("destructor runs");
15+
error2!("destructor runs");
1616
}
1717
}
1818

1919
fn main() {
2020
let x = Some((X { x: () }, X { x: () }));
2121
match x {
2222
Some((ref _y, _z)) => { }, //~ ERROR cannot bind by-move and by-ref in the same pattern
23-
None => fail!()
23+
None => fail2!()
2424
}
2525
}

branches/snap-stage3/src/test/compile-fail/bind-by-move-neither-can-live-while-the-other-survives-3.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ struct X { x: (), }
1212

1313
impl Drop for X {
1414
fn drop(&mut self) {
15-
error!("destructor runs");
15+
error2!("destructor runs");
1616
}
1717
}
1818

@@ -22,6 +22,6 @@ fn main() {
2222
let x = some2(X { x: () }, X { x: () });
2323
match x {
2424
some2(ref _y, _z) => { }, //~ ERROR cannot bind by-move and by-ref in the same pattern
25-
none2 => fail!()
25+
none2 => fail2!()
2626
}
2727
}

branches/snap-stage3/src/test/compile-fail/bind-by-move-neither-can-live-while-the-other-survives-4.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ struct X { x: (), }
1212

1313
impl Drop for X {
1414
fn drop(&mut self) {
15-
error!("destructor runs");
15+
error2!("destructor runs");
1616
}
1717
}
1818

1919
fn main() {
2020
let x = Some((X { x: () }, X { x: () }));
2121
match x {
2222
Some((_y, ref _z)) => { }, //~ ERROR cannot bind by-move and by-ref in the same pattern
23-
None => fail!()
23+
None => fail2!()
2424
}
2525
}

branches/snap-stage3/src/test/compile-fail/bind-by-move-no-guards.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ fn main() {
1515
let x = Some(p);
1616
c.send(false);
1717
match x {
18-
Some(z) if z.recv() => { fail!() }, //~ ERROR cannot bind by-move into a pattern guard
18+
Some(z) if z.recv() => { fail2!() }, //~ ERROR cannot bind by-move into a pattern guard
1919
Some(z) => { assert!(!z.recv()); },
20-
None => fail!()
20+
None => fail2!()
2121
}
2222
}

branches/snap-stage3/src/test/compile-fail/bind-by-move-no-sub-bindings.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,14 @@ struct X { x: (), }
1212

1313
impl Drop for X {
1414
fn drop(&mut self) {
15-
error!("destructor runs");
15+
error2!("destructor runs");
1616
}
1717
}
1818

1919
fn main() {
2020
let x = Some(X { x: () });
2121
match x {
2222
Some(_y @ ref _z) => { }, //~ ERROR cannot bind by-move with sub-bindings
23-
None => fail!()
23+
None => fail2!()
2424
}
2525
}

branches/snap-stage3/src/test/compile-fail/block-arg-as-stmt-with-value.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,6 @@ fn compute1() -> float {
1717

1818
fn main() {
1919
let x = compute1();
20-
info!(x);
20+
info2!("{:?}", x);
2121
assert_eq!(x, -4f);
2222
}

branches/snap-stage3/src/test/compile-fail/block-coerce-no.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@ fn coerce(b: &fn()) -> extern fn() {
2121

2222
fn main() {
2323
let i = 8;
24-
let f = coerce(|| error!(i) );
24+
let f = coerce(|| error2!("{:?}", i) );
2525
f();
2626
}

branches/snap-stage3/src/test/compile-fail/bogus-tag.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ enum color { rgb(int, int, int), rgba(int, int, int, int), }
1717
fn main() {
1818
let red: color = rgb(255, 0, 0);
1919
match red {
20-
rgb(r, g, b) => { info!("rgb"); }
21-
hsl(h, s, l) => { info!("hsl"); }
20+
rgb(r, g, b) => { info2!("rgb"); }
21+
hsl(h, s, l) => { info2!("hsl"); }
2222
}
2323
}

branches/snap-stage3/src/test/compile-fail/borrowck-anon-fields-variant.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ fn distinct_variant() {
1010

1111
let a = match y {
1212
Y(ref mut a, _) => a,
13-
X => fail!()
13+
X => fail2!()
1414
};
1515

1616
let b = match y {
1717
Y(_, ref mut b) => b,
18-
X => fail!()
18+
X => fail2!()
1919
};
2020

2121
*a += 1;
@@ -27,12 +27,12 @@ fn same_variant() {
2727

2828
let a = match y {
2929
Y(ref mut a, _) => a,
30-
X => fail!()
30+
X => fail2!()
3131
};
3232

3333
let b = match y {
3434
Y(ref mut b, _) => b, //~ ERROR cannot borrow
35-
X => fail!()
35+
X => fail2!()
3636
};
3737

3838
*a += 1;

branches/snap-stage3/src/test/compile-fail/borrowck-assign-comp-idx.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ fn a() {
2121

2222
p[0] = 5; //~ ERROR cannot assign
2323

24-
info!("%d", *q);
24+
info2!("{}", *q);
2525
}
2626

2727
fn borrow(_x: &[int], _f: &fn()) {}

branches/snap-stage3/src/test/compile-fail/borrowck-autoref-3261.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ fn main() {
2424
x = X(Left((0,0))); //~ ERROR cannot assign to `x`
2525
(*f)()
2626
},
27-
_ => fail!()
27+
_ => fail2!()
2828
}
2929
}
3030
}

branches/snap-stage3/src/test/compile-fail/borrowck-borrow-from-owned-ptr.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ struct Bar {
1818
int2: int,
1919
}
2020

21-
fn make_foo() -> ~Foo { fail!() }
21+
fn make_foo() -> ~Foo { fail2!() }
2222

2323
fn borrow_same_field_twice_mut_mut() {
2424
let mut foo = make_foo();

branches/snap-stage3/src/test/compile-fail/borrowck-borrow-from-stack-variable.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ struct Bar {
1818
int2: int,
1919
}
2020

21-
fn make_foo() -> Foo { fail!() }
21+
fn make_foo() -> Foo { fail2!() }
2222

2323
fn borrow_same_field_twice_mut_mut() {
2424
let mut foo = make_foo();

branches/snap-stage3/src/test/compile-fail/borrowck-borrowed-uniq-rvalue-2.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ struct defer<'self> {
1616
impl<'self> Drop for defer<'self> {
1717
fn drop(&mut self) {
1818
unsafe {
19-
error!("%?", self.x);
19+
error2!("{:?}", self.x);
2020
}
2121
}
2222
}

branches/snap-stage3/src/test/compile-fail/borrowck-lend-flow-if.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616

1717
fn borrow(_v: &int) {}
1818
fn borrow_mut(_v: &mut int) {}
19-
fn cond() -> bool { fail!() }
20-
fn for_func(_f: &fn() -> bool) { fail!() }
21-
fn produce<T>() -> T { fail!(); }
19+
fn cond() -> bool { fail2!() }
20+
fn for_func(_f: &fn() -> bool) { fail2!() }
21+
fn produce<T>() -> T { fail2!(); }
2222

2323
fn inc(v: &mut ~int) {
2424
*v = ~(**v + 1);

branches/snap-stage3/src/test/compile-fail/borrowck-lend-flow-loop.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616

1717
fn borrow(_v: &int) {}
1818
fn borrow_mut(_v: &mut int) {}
19-
fn cond() -> bool { fail!() }
20-
fn produce<T>() -> T { fail!(); }
19+
fn cond() -> bool { fail2!() }
20+
fn produce<T>() -> T { fail2!(); }
2121

2222
fn inc(v: &mut ~int) {
2323
*v = ~(**v + 1);

branches/snap-stage3/src/test/compile-fail/borrowck-lend-flow-match.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#[allow(unused_variable)];
1414
#[allow(dead_assignment)];
1515

16-
fn cond() -> bool { fail!() }
16+
fn cond() -> bool { fail2!() }
1717
fn link<'a>(v: &'a uint, w: &mut &'a uint) -> bool { *w = v; true }
1818

1919
fn separate_arms() {

branches/snap-stage3/src/test/compile-fail/borrowck-lend-flow.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616

1717
fn borrow(_v: &int) {}
1818
fn borrow_mut(_v: &mut int) {}
19-
fn cond() -> bool { fail!() }
20-
fn for_func(_f: &fn() -> bool) { fail!() }
21-
fn produce<T>() -> T { fail!(); }
19+
fn cond() -> bool { fail2!() }
20+
fn for_func(_f: &fn() -> bool) { fail2!() }
21+
fn produce<T>() -> T { fail2!(); }
2222

2323
fn inc(v: &mut ~int) {
2424
*v = ~(**v + 1);

branches/snap-stage3/src/test/compile-fail/borrowck-loan-blocks-move-cc.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,14 @@ fn box_imm() {
1818
let v = ~3;
1919
let _w = &v;
2020
do task::spawn {
21-
info!("v=%d", *v);
21+
info2!("v={}", *v);
2222
//~^ ERROR cannot move `v` into closure
2323
}
2424

2525
let v = ~3;
2626
let _w = &v;
2727
task::spawn(|| {
28-
info!("v=%d", *v);
28+
info2!("v={}", *v);
2929
//~^ ERROR cannot move
3030
});
3131
}

branches/snap-stage3/src/test/compile-fail/borrowck-loan-local-as-both-mut-and-imm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ use std::either::{Either, Left, Right};
1616
*x = Right(1.0);
1717
*z
1818
}
19-
_ => fail!()
19+
_ => fail2!()
2020
}
2121
}
2222

branches/snap-stage3/src/test/compile-fail/borrowck-move-out-of-vec-tail.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ pub fn main() {
2323
}
2424
}
2525
let z = tail[0].clone();
26-
info!(fmt!("%?", z));
26+
info2!("{:?}", z);
2727
}
2828
_ => {
2929
unreachable!();

branches/snap-stage3/src/test/compile-fail/borrowck-mut-addr-of-imm-var.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@ fn main() {
1212
let x: int = 3;
1313
let y: &mut int = &mut x; //~ ERROR cannot borrow
1414
*y = 5;
15-
info!(*y);
15+
info2!("{:?}", *y);
1616
}

branches/snap-stage3/src/test/compile-fail/borrowck-ref-into-rvalue.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ fn main() {
1414
Some(ref m) => { //~ ERROR borrowed value does not live long enough
1515
msg = m;
1616
},
17-
None => { fail!() }
17+
None => { fail2!() }
1818
}
1919
println(*msg);
2020
}

branches/snap-stage3/src/test/compile-fail/borrowck-vec-pattern-element-loan.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ fn a() -> &[int] {
22
let vec = ~[1, 2, 3, 4];
33
let tail = match vec {
44
[_, ..tail] => tail, //~ ERROR does not live long enough
5-
_ => fail!("a")
5+
_ => fail2!("a")
66
};
77
tail
88
}
@@ -11,7 +11,7 @@ fn b() -> &[int] {
1111
let vec = ~[1, 2, 3, 4];
1212
let init = match vec {
1313
[..init, _] => init, //~ ERROR does not live long enough
14-
_ => fail!("b")
14+
_ => fail2!("b")
1515
};
1616
init
1717
}
@@ -20,7 +20,7 @@ fn c() -> &[int] {
2020
let vec = ~[1, 2, 3, 4];
2121
let slice = match vec {
2222
[_, ..slice, _] => slice, //~ ERROR does not live long enough
23-
_ => fail!("c")
23+
_ => fail2!("c")
2424
};
2525
slice
2626
}

branches/snap-stage3/src/test/compile-fail/borrowck-vec-pattern-nesting.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ fn a() {
44
[~ref _a] => {
55
vec[0] = ~4; //~ ERROR cannot assign to `(*vec)[]` because it is borrowed
66
}
7-
_ => fail!("foo")
7+
_ => fail2!("foo")
88
}
99
}
1010

branches/snap-stage3/src/test/compile-fail/borrowck-vec-pattern-tail-element-loan.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ fn a() -> &int {
22
let vec = ~[1, 2, 3, 4];
33
let tail = match vec {
44
[_a, ..tail] => &tail[0], //~ ERROR borrowed value does not live long enough
5-
_ => fail!("foo")
5+
_ => fail2!("foo")
66
};
77
tail
88
}

0 commit comments

Comments
 (0)