diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2016-10-12 10:15:26 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2016-10-12 14:07:55 -0700 |
| commit | 9d70ff384f4a87e2cfe3d5e90b27637632bb373a (patch) | |
| tree | ef14774ca0dfd2daabeee9dad6da56be1b36106d /src/test | |
| parent | d13b102c5463d4258482815d04b93f360418245f (diff) | |
| parent | 79b5177378097ee39e595517ca76132b3a3dc0eb (diff) | |
| download | rust-9d70ff384f4a87e2cfe3d5e90b27637632bb373a.tar.gz rust-9d70ff384f4a87e2cfe3d5e90b27637632bb373a.zip | |
Rollup merge of #36995 - nrc:stable, r=@nikomatsakis
stabilise ?, attributes on stmts, deprecate Reflect r? @nikomatsakis
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/compile-fail/feature-gate-try-operator.rs | 18 | ||||
| -rw-r--r-- | src/test/compile-fail/issue-32709.rs | 4 | ||||
| -rw-r--r-- | src/test/compile-fail/issue-33876.rs | 3 | ||||
| -rw-r--r-- | src/test/compile-fail/mir-dataflow/def-inits-1.rs | 1 | ||||
| -rw-r--r-- | src/test/compile-fail/mir-dataflow/inits-1.rs | 1 | ||||
| -rw-r--r-- | src/test/compile-fail/mir-dataflow/uninits-1.rs | 1 | ||||
| -rw-r--r-- | src/test/compile-fail/mir-dataflow/uninits-2.rs | 1 | ||||
| -rw-r--r-- | src/test/compile-fail/stmt_expr_attrs_no_feature.rs | 16 | ||||
| -rw-r--r-- | src/test/run-pass/const-negation.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/enum-discrim-autosizing.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/ifmt.rs | 1 | ||||
| -rw-r--r-- | src/test/run-pass/impl-trait/example-st.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/issue-17121.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/issue-19404.rs | 5 | ||||
| -rw-r--r-- | src/test/run-pass/issue-20797.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/issue-21400.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/issue-8460.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/try-operator-hygiene.rs | 2 | ||||
| -rw-r--r-- | src/test/run-pass/try-operator.rs | 2 |
19 files changed, 12 insertions, 57 deletions
diff --git a/src/test/compile-fail/feature-gate-try-operator.rs b/src/test/compile-fail/feature-gate-try-operator.rs deleted file mode 100644 index b05c7323962..00000000000 --- a/src/test/compile-fail/feature-gate-try-operator.rs +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2016 The Rust Project Developers. See the COPYRIGHT -// file at the top-level directory of this distribution and at -// http://rust-lang.org/COPYRIGHT. -// -// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or -// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license -// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your -// option. This file may not be copied, modified, or distributed -// except according to those terms. - -macro_rules! id { - ($e:expr) => { $e } -} - -fn main() { - id!(x?); //~ error: the `?` operator is not stable (see issue #31436) - y?; //~ error: the `?` operator is not stable (see issue #31436) -} diff --git a/src/test/compile-fail/issue-32709.rs b/src/test/compile-fail/issue-32709.rs index f9d11f3a171..09538818dcd 100644 --- a/src/test/compile-fail/issue-32709.rs +++ b/src/test/compile-fail/issue-32709.rs @@ -8,12 +8,10 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(question_mark)] - // Make sure that the span of try shorthand does not include the trailing // semicolon; fn a() -> Result<i32, ()> { - Err(5)?; //~ ERROR 16:5: 16:12 + Err(5)?; //~ ERROR 14:5: 14:12 Ok(1) } diff --git a/src/test/compile-fail/issue-33876.rs b/src/test/compile-fail/issue-33876.rs index d95890730a0..87747d2851f 100644 --- a/src/test/compile-fail/issue-33876.rs +++ b/src/test/compile-fail/issue-33876.rs @@ -8,9 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(reflect_marker)] - -use std::marker::Reflect; use std::any::Any; struct Foo; diff --git a/src/test/compile-fail/mir-dataflow/def-inits-1.rs b/src/test/compile-fail/mir-dataflow/def-inits-1.rs index a133ddc15f1..1ba1bb35bb5 100644 --- a/src/test/compile-fail/mir-dataflow/def-inits-1.rs +++ b/src/test/compile-fail/mir-dataflow/def-inits-1.rs @@ -11,7 +11,6 @@ // General test of maybe_uninits state computed by MIR dataflow. #![feature(rustc_attrs)] -#![feature(stmt_expr_attributes)] use std::intrinsics::rustc_peek; use std::mem::{drop, replace}; diff --git a/src/test/compile-fail/mir-dataflow/inits-1.rs b/src/test/compile-fail/mir-dataflow/inits-1.rs index 949688098f6..c8cf44adb97 100644 --- a/src/test/compile-fail/mir-dataflow/inits-1.rs +++ b/src/test/compile-fail/mir-dataflow/inits-1.rs @@ -11,7 +11,6 @@ // General test of maybe_inits state computed by MIR dataflow. #![feature(rustc_attrs)] -#![feature(stmt_expr_attributes)] use std::intrinsics::rustc_peek; use std::mem::{drop, replace}; diff --git a/src/test/compile-fail/mir-dataflow/uninits-1.rs b/src/test/compile-fail/mir-dataflow/uninits-1.rs index c13daae24f3..a82bfc89698 100644 --- a/src/test/compile-fail/mir-dataflow/uninits-1.rs +++ b/src/test/compile-fail/mir-dataflow/uninits-1.rs @@ -11,7 +11,6 @@ // General test of maybe_uninits state computed by MIR dataflow. #![feature(rustc_attrs)] -#![feature(stmt_expr_attributes)] use std::intrinsics::rustc_peek; use std::mem::{drop, replace}; diff --git a/src/test/compile-fail/mir-dataflow/uninits-2.rs b/src/test/compile-fail/mir-dataflow/uninits-2.rs index 94f812a40a9..8cfdae50662 100644 --- a/src/test/compile-fail/mir-dataflow/uninits-2.rs +++ b/src/test/compile-fail/mir-dataflow/uninits-2.rs @@ -11,7 +11,6 @@ // General test of maybe_uninits state computed by MIR dataflow. #![feature(rustc_attrs)] -#![feature(stmt_expr_attributes)] use std::intrinsics::rustc_peek; use std::mem::{drop, replace}; diff --git a/src/test/compile-fail/stmt_expr_attrs_no_feature.rs b/src/test/compile-fail/stmt_expr_attrs_no_feature.rs index 68338b11595..2fda2ee0900 100644 --- a/src/test/compile-fail/stmt_expr_attrs_no_feature.rs +++ b/src/test/compile-fail/stmt_expr_attrs_no_feature.rs @@ -21,15 +21,15 @@ fn main() { #[attr] fn a() {} - #[attr] //~ ERROR 15701 + #[attr] { } - #[attr] //~ ERROR 15701 + #[attr] 5; - #[attr] //~ ERROR 15701 + #[attr] stmt_mac!(); } @@ -43,7 +43,7 @@ fn c() { #[cfg(not(unset))] fn j() { - #[attr] //~ ERROR 15701 + #[attr] 5; } @@ -55,7 +55,7 @@ fn d() { #[cfg_attr(not(unset), cfg(not(unset)))] fn i() { - #[attr] //~ ERROR 15701 + #[attr] 8; } @@ -64,7 +64,7 @@ fn i() { macro_rules! item_mac { ($e:ident) => { fn $e() { - #[attr] //~ ERROR 15701 + #[attr] 42; #[cfg(unset)] @@ -75,7 +75,7 @@ macro_rules! item_mac { #[cfg(not(unset))] fn k() { - #[attr] //~ ERROR 15701 + #[attr] 5; } @@ -87,7 +87,7 @@ macro_rules! item_mac { #[cfg_attr(not(unset), cfg(not(unset)))] fn h() { - #[attr] //~ ERROR 15701 + #[attr] 8; } diff --git a/src/test/run-pass/const-negation.rs b/src/test/run-pass/const-negation.rs index 96f4217e4cb..012fe0d95ec 100644 --- a/src/test/run-pass/const-negation.rs +++ b/src/test/run-pass/const-negation.rs @@ -8,8 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(stmt_expr_attributes)] - #[deny(const_err)] fn main() { diff --git a/src/test/run-pass/enum-discrim-autosizing.rs b/src/test/run-pass/enum-discrim-autosizing.rs index 53c44f2bb24..c85ab535fc1 100644 --- a/src/test/run-pass/enum-discrim-autosizing.rs +++ b/src/test/run-pass/enum-discrim-autosizing.rs @@ -8,8 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(stmt_expr_attributes)] - use std::mem::size_of; enum Ei8 { diff --git a/src/test/run-pass/ifmt.rs b/src/test/run-pass/ifmt.rs index 8b5536de12e..0ebe1ca07c7 100644 --- a/src/test/run-pass/ifmt.rs +++ b/src/test/run-pass/ifmt.rs @@ -14,7 +14,6 @@ #![allow(unused_must_use)] #![allow(unused_features)] #![feature(box_syntax)] -#![feature(question_mark)] use std::fmt::{self, Write}; use std::usize; diff --git a/src/test/run-pass/impl-trait/example-st.rs b/src/test/run-pass/impl-trait/example-st.rs index 461d4cf4ff0..e9326ed286a 100644 --- a/src/test/run-pass/impl-trait/example-st.rs +++ b/src/test/run-pass/impl-trait/example-st.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(conservative_impl_trait, question_mark)] +#![feature(conservative_impl_trait)] struct State; type Error = (); diff --git a/src/test/run-pass/issue-17121.rs b/src/test/run-pass/issue-17121.rs index b3c80041ef8..dcbcc2d44b5 100644 --- a/src/test/run-pass/issue-17121.rs +++ b/src/test/run-pass/issue-17121.rs @@ -10,8 +10,6 @@ // pretty-expanded FIXME #23616 -#![feature(question_mark)] - use std::fs::File; use std::io::{self, BufReader, Read}; diff --git a/src/test/run-pass/issue-19404.rs b/src/test/run-pass/issue-19404.rs index 0eea6ba22ca..c0f13b0b6c7 100644 --- a/src/test/run-pass/issue-19404.rs +++ b/src/test/run-pass/issue-19404.rs @@ -8,17 +8,14 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(reflect_marker)] - use std::any::TypeId; -use std::marker::Reflect; use std::rc::Rc; type Fp<T> = Rc<T>; struct Engine; -trait Component: 'static + Reflect {} +trait Component: 'static {} impl Component for Engine {} trait Env { diff --git a/src/test/run-pass/issue-20797.rs b/src/test/run-pass/issue-20797.rs index de952436650..e45582dc2d3 100644 --- a/src/test/run-pass/issue-20797.rs +++ b/src/test/run-pass/issue-20797.rs @@ -10,8 +10,6 @@ // Regression test for #20797. -#![feature(question_mark)] - use std::default::Default; use std::io; use std::fs; diff --git a/src/test/run-pass/issue-21400.rs b/src/test/run-pass/issue-21400.rs index 0d1be964748..6715b71a5f5 100644 --- a/src/test/run-pass/issue-21400.rs +++ b/src/test/run-pass/issue-21400.rs @@ -11,8 +11,6 @@ // Regression test for #21400 which itself was extracted from // stackoverflow.com/questions/28031155/is-my-borrow-checker-drunk/28031580 -#![feature(question_mark)] - fn main() { let mut t = Test; assert_eq!(t.method1("one"), Ok(1)); diff --git a/src/test/run-pass/issue-8460.rs b/src/test/run-pass/issue-8460.rs index 8d15fe30a1b..f16057ccab1 100644 --- a/src/test/run-pass/issue-8460.rs +++ b/src/test/run-pass/issue-8460.rs @@ -11,7 +11,7 @@ // ignore-emscripten no threads support // ignore-pretty : (#23623) problems when ending with // comments -#![feature(rustc_attrs, stmt_expr_attributes, zero_one)] +#![feature(rustc_attrs, zero_one)] use std::num::Zero; use std::thread; diff --git a/src/test/run-pass/try-operator-hygiene.rs b/src/test/run-pass/try-operator-hygiene.rs index ae622df498f..53d6185020a 100644 --- a/src/test/run-pass/try-operator-hygiene.rs +++ b/src/test/run-pass/try-operator-hygiene.rs @@ -18,8 +18,6 @@ // This test verifies that the expansion is hygienic, i.e. it's not affected by other `val` and // `err` bindings that may be in scope. -#![feature(question_mark)] - use std::num::ParseIntError; fn main() { diff --git a/src/test/run-pass/try-operator.rs b/src/test/run-pass/try-operator.rs index de5ccf09c59..29de6364bf1 100644 --- a/src/test/run-pass/try-operator.rs +++ b/src/test/run-pass/try-operator.rs @@ -8,8 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#![feature(question_mark)] - use std::fs::File; use std::io::{Read, self}; use std::num::ParseIntError; |
