Skip to content

Commit 1bbf718

Browse files
committed
Fix tests for rustc_*
1 parent 0129002 commit 1bbf718

15 files changed

+30
-0
lines changed

src/test/compile-fail/move-fragments-1.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
// These are all fairly trivial cases: unused variables or direct
1919
// drops of substructure.
2020

21+
#![feature(rustc_attrs)]
22+
2123
pub struct D { d: isize }
2224
impl Drop for D { fn drop(&mut self) { } }
2325

src/test/compile-fail/move-fragments-2.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
// These are checking that enums are tracked; note that their output
1919
// paths include "downcasts" of the path to a particular enum.
2020

21+
#![feature(rustc_attrs)]
22+
2123
use self::Lonely::{Zero, One, Two};
2224

2325
pub struct D { d: isize }

src/test/compile-fail/move-fragments-3.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
// This checks the handling of `_` within variants, especially when mixed
1919
// with bindings.
2020

21+
#![feature(rustc_attrs)]
22+
2123
use self::Lonely::{Zero, One, Two};
2224

2325
pub struct D { d: isize }

src/test/compile-fail/move-fragments-4.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
// early draft of the code did not properly traverse up through all of
2020
// the parents of the leaf fragment.)
2121

22+
#![feature(rustc_attrs)]
23+
2224
pub struct D { d: isize }
2325
impl Drop for D { fn drop(&mut self) { } }
2426

src/test/compile-fail/move-fragments-5.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717

1818
// This is the first test that checks moving into local variables.
1919

20+
#![feature(rustc_attrs)]
21+
2022
pub struct D { d: isize }
2123
impl Drop for D { fn drop(&mut self) { } }
2224

src/test/compile-fail/move-fragments-6.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
// Test that moving into a field (i.e. overwriting it) fragments the
1919
// receiver.
2020

21+
#![feature(rustc_attrs)]
22+
2123
use std::mem::drop;
2224

2325
pub struct Pair<X,Y> { x: X, y: Y }

src/test/compile-fail/move-fragments-7.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
// both moving out of the structure (i.e. reading `*p.x`) and writing
2020
// into the container (i.e. writing `*p.x`).
2121

22+
#![feature(rustc_attrs)]
23+
2224
pub struct D { d: isize }
2325
impl Drop for D { fn drop(&mut self) { } }
2426

src/test/compile-fail/move-fragments-8.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
// also that in this case we cannot do a move out of `&T`, so we only
2323
// test writing `*p.x` here.
2424

25+
#![feature(rustc_attrs)]
26+
2527
pub struct D { d: isize }
2628
impl Drop for D { fn drop(&mut self) { } }
2729

src/test/compile-fail/move-fragments-9.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414
// Note also that the `test_move_array_then_overwrite` tests represent
1515
// cases that we probably should make illegal.
1616

17+
#![feature(rustc_attrs)]
18+
1719
pub struct D { d: isize }
1820
impl Drop for D { fn drop(&mut self) { } }
1921

src/test/compile-fail/rustc-error.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11+
#![feature(rustc_attrs)]
12+
1113
#[rustc_error]
1214
fn main() {
1315
//~^ ERROR compilation successful

0 commit comments

Comments
 (0)