Fix run-pass-fulldeps tests

This commit is contained in:
varkor 2018-07-24 18:24:12 +01:00
parent f2fd00005e
commit f22ccbe315
35 changed files with 20 additions and 89 deletions

View File

@ -36,16 +36,16 @@
#![feature(staged_api)] #![feature(staged_api)]
#![stable(feature = "unit_test", since = "0.0.0")] #![stable(feature = "unit_test", since = "1.0.0")]
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub use m::{Record, Trait, Tuple}; pub use m::{Record, Trait, Tuple};
mod m { mod m {
#[derive(Default)] #[derive(Default)]
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub struct Record { pub struct Record {
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub a_stable_pub: i32, pub a_stable_pub: i32,
#[unstable(feature = "unstable_declared", issue = "38412")] #[unstable(feature = "unstable_declared", issue = "38412")]
pub a_unstable_declared_pub: i32, pub a_unstable_declared_pub: i32,
@ -55,14 +55,14 @@ mod m {
pub(crate) b_crate: i32, pub(crate) b_crate: i32,
#[unstable(feature = "unstable_declared", issue = "38412")] // SILLY #[unstable(feature = "unstable_declared", issue = "38412")] // SILLY
pub(in m) c_mod: i32, pub(in m) c_mod: i32,
#[stable(feature = "unit_test", since = "0.0.0")] // SILLY #[stable(feature = "unit_test", since = "1.0.0")] // SILLY
d_priv: i32 d_priv: i32
} }
#[derive(Default)] #[derive(Default)]
#[stable(feature = "unit_test", since = "1.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub struct Tuple( pub struct Tuple(
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub i32, pub i32,
#[unstable(feature = "unstable_declared", issue = "38412")] #[unstable(feature = "unstable_declared", issue = "38412")]
pub i32, pub i32,
@ -84,11 +84,11 @@ mod m {
} }
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub trait Trait { pub trait Trait {
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
type Type; type Type;
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
fn stable_trait_method(&self) -> Self::Type; fn stable_trait_method(&self) -> Self::Type;
#[unstable(feature = "unstable_undeclared", issue = "38412")] #[unstable(feature = "unstable_undeclared", issue = "38412")]
fn unstable_undeclared_trait_method(&self) -> Self::Type; fn unstable_undeclared_trait_method(&self) -> Self::Type;
@ -96,7 +96,7 @@ mod m {
fn unstable_declared_trait_method(&self) -> Self::Type; fn unstable_declared_trait_method(&self) -> Self::Type;
} }
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
impl Trait for Record { impl Trait for Record {
type Type = i32; type Type = i32;
fn stable_trait_method(&self) -> i32 { self.d_priv } fn stable_trait_method(&self) -> i32 { self.d_priv }
@ -104,7 +104,7 @@ mod m {
fn unstable_declared_trait_method(&self) -> i32 { self.d_priv } fn unstable_declared_trait_method(&self) -> i32 { self.d_priv }
} }
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
impl Trait for Tuple { impl Trait for Tuple {
type Type = i32; type Type = i32;
fn stable_trait_method(&self) -> i32 { self.3 } fn stable_trait_method(&self) -> i32 { self.3 }
@ -117,14 +117,14 @@ mod m {
pub fn unstable_undeclared(&self) -> i32 { self.d_priv } pub fn unstable_undeclared(&self) -> i32 { self.d_priv }
#[unstable(feature = "unstable_declared", issue = "38412")] #[unstable(feature = "unstable_declared", issue = "38412")]
pub fn unstable_declared(&self) -> i32 { self.d_priv } pub fn unstable_declared(&self) -> i32 { self.d_priv }
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub fn stable(&self) -> i32 { self.d_priv } pub fn stable(&self) -> i32 { self.d_priv }
#[unstable(feature = "unstable_undeclared", issue = "38412")] // SILLY #[unstable(feature = "unstable_undeclared", issue = "38412")] // SILLY
pub(crate) fn pub_crate(&self) -> i32 { self.d_priv } pub(crate) fn pub_crate(&self) -> i32 { self.d_priv }
#[unstable(feature = "unstable_declared", issue = "38412")] // SILLY #[unstable(feature = "unstable_declared", issue = "38412")] // SILLY
pub(in m) fn pub_mod(&self) -> i32 { self.d_priv } pub(in m) fn pub_mod(&self) -> i32 { self.d_priv }
#[stable(feature = "unit_test", since = "0.0.0")] // SILLY #[stable(feature = "unit_test", since = "1.0.0")] // SILLY
fn private(&self) -> i32 { self.d_priv } fn private(&self) -> i32 { self.d_priv }
} }
@ -133,7 +133,7 @@ mod m {
pub fn unstable_undeclared(&self) -> i32 { self.0 } pub fn unstable_undeclared(&self) -> i32 { self.0 }
#[unstable(feature = "unstable_declared", issue = "38412")] #[unstable(feature = "unstable_declared", issue = "38412")]
pub fn unstable_declared(&self) -> i32 { self.0 } pub fn unstable_declared(&self) -> i32 { self.0 }
#[stable(feature = "unit_test", since = "0.0.0")] #[stable(feature = "unit_test", since = "1.0.0")]
pub fn stable(&self) -> i32 { self.0 } pub fn stable(&self) -> i32 { self.0 }
pub(crate) fn pub_crate(&self) -> i32 { self.0 } pub(crate) fn pub_crate(&self) -> i32 { self.0 }

View File

@ -9,7 +9,7 @@
// except according to those terms. // except according to those terms.
#![feature(staged_api)] #![feature(staged_api)]
#![stable(feature = "unit_test", since = "0.0.0")] #![stable(feature = "unit_test", since = "1.0.0")]
#[unstable(feature = "unstable_macros", issue = "0")] #[unstable(feature = "unstable_macros", issue = "0")]
#[macro_export] #[macro_export]

View File

@ -12,8 +12,7 @@
// ignore-cross-compile // ignore-cross-compile
#![feature(rustc_private, path)] #![feature(rustc_private)]
#![feature(core)]
extern crate getopts; extern crate getopts;
extern crate rustc; extern crate rustc;

View File

@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(rand, rustc_private)] #![feature(rustc_private)]
extern crate serialize; extern crate serialize;

View File

@ -11,7 +11,7 @@
// aux-build:attr-stmt-expr.rs // aux-build:attr-stmt-expr.rs
// ignore-stage1 // ignore-stage1
#![feature(use_extern_macros, stmt_expr_attributes, proc_macro_stmt, proc_macro_expr)] #![feature(use_extern_macros, stmt_expr_attributes, proc_macro_expr)]
extern crate attr_stmt_expr; extern crate attr_stmt_expr;
use attr_stmt_expr::{expect_let, expect_print_stmt, expect_expr, expect_print_expr, use attr_stmt_expr::{expect_let, expect_print_stmt, expect_expr, expect_print_expr,

View File

@ -12,8 +12,6 @@
// pretty-expanded FIXME #23616 // pretty-expanded FIXME #23616
#![feature(core)]
use std::slice; use std::slice;
trait Bound {} trait Bound {}

View File

@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
pub mod testtypes { pub mod testtypes {
use std::any::TypeId; use std::any::TypeId;

View File

@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
use std::any::{Any, TypeId}; use std::any::{Any, TypeId};
pub struct A; pub struct A;

View File

@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
use std::any::{Any, TypeId}; use std::any::{Any, TypeId};
pub struct A; pub struct A;

View File

@ -9,7 +9,7 @@
// except according to those terms. // except according to those terms.
#![feature(staged_api)] #![feature(staged_api)]
#![stable(feature = "unit_test", since = "0.0.0")] #![stable(feature = "unit_test", since = "1.0.0")]
#[unstable(feature = "unstable_macros", issue = "0")] #[unstable(feature = "unstable_macros", issue = "0")]
#[macro_export] #[macro_export]

View File

@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
pub trait DeclaredTrait { pub trait DeclaredTrait {
type Type; type Type;
} }

View File

@ -11,9 +11,6 @@
// Test that overloaded index expressions with DST result types // Test that overloaded index expressions with DST result types
// work and don't ICE. // work and don't ICE.
#![feature(core)]
use std::ops::Index; use std::ops::Index;
use std::fmt::Debug; use std::fmt::Debug;

View File

@ -8,9 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
use std::ops::Add; use std::ops::Add;
extern "C" fn foo<T: Add>(a: T, b: T) -> T::Output { a + b } extern "C" fn foo<T: Add>(a: T, b: T) -> T::Output { a + b }

View File

@ -11,9 +11,6 @@
// If `Index` used an associated type for its output, this test would // If `Index` used an associated type for its output, this test would
// work more smoothly. // work more smoothly.
#![feature(core)]
use std::ops::Index; use std::ops::Index;
struct Mat<T> { data: Vec<T>, cols: usize, } struct Mat<T> { data: Vec<T>, cols: usize, }

View File

@ -10,8 +10,6 @@
// pretty-expanded FIXME #23616 // pretty-expanded FIXME #23616
#![feature(core)]
trait Str { fn foo(&self) {} } trait Str { fn foo(&self) {} }
impl Str for str {} impl Str for str {}
impl<'a, S: ?Sized> Str for &'a S where S: Str {} impl<'a, S: ?Sized> Str for &'a S where S: Str {}

View File

@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
extern crate core; extern crate core;
use core::marker::Sync; use core::marker::Sync;

View File

@ -10,8 +10,6 @@
// pretty-expanded FIXME #23616 // pretty-expanded FIXME #23616
#![feature(core)]
// This used to cause an ICE because the retslot for the "return" had the wrong type // This used to cause an ICE because the retslot for the "return" had the wrong type
fn testcase<'a>() -> Box<Iterator<Item=usize> + 'a> { fn testcase<'a>() -> Box<Iterator<Item=usize> + 'a> {
return Box::new((0..3).map(|i| { return i; })); return Box::new((0..3).map(|i| { return i; }));

View File

@ -22,8 +22,6 @@
// that are already linked in. Using WriterUtil allows us to use the write_line // that are already linked in. Using WriterUtil allows us to use the write_line
// method. // method.
#![feature(core)]
use std::fmt; use std::fmt;
use std::iter::repeat; use std::iter::repeat;
use std::slice; use std::slice;

View File

@ -12,8 +12,6 @@
// Issue Name: pub method preceded by attribute can't be parsed // Issue Name: pub method preceded by attribute can't be parsed
// Abstract: Visibility parsing failed when compiler parsing // Abstract: Visibility parsing failed when compiler parsing
#![feature(core)]
use std::f64; use std::f64;
#[derive(Copy, Clone)] #[derive(Copy, Clone)]

View File

@ -13,8 +13,6 @@
// pretty-expanded FIXME #23616 // pretty-expanded FIXME #23616
#![feature(core)]
trait A { trait A {
fn foo(self); fn foo(self);
} }

View File

@ -8,8 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
use std::cmp; use std::cmp;
use std::ops; use std::ops;

View File

@ -11,9 +11,6 @@
// Test overloading of the `[]` operator. In particular test that it // Test overloading of the `[]` operator. In particular test that it
// takes its argument *by reference*. // takes its argument *by reference*.
#![feature(core)]
use std::ops::Index; use std::ops::Index;
struct AssociationList<K,V> { struct AssociationList<K,V> {

View File

@ -11,9 +11,6 @@
// Test using overloaded indexing when the "map" is stored in a // Test using overloaded indexing when the "map" is stored in a
// field. This caused problems at some point. // field. This caused problems at some point.
#![feature(core)]
use std::ops::Index; use std::ops::Index;
struct Foo { struct Foo {

View File

@ -8,9 +8,6 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![feature(core)]
use std::ops::{Index, IndexMut}; use std::ops::{Index, IndexMut};
struct Foo { struct Foo {

View File

@ -14,7 +14,6 @@
// ignore-bitrig // ignore-bitrig
// compile-flags: -C codegen_units=2 // compile-flags: -C codegen_units=2
#![feature(core)]
#![feature(iter_arith)] #![feature(iter_arith)]
mod a { mod a {

View File

@ -10,9 +10,6 @@
// Test slicing sugar. // Test slicing sugar.
#![feature(core)]
extern crate core; extern crate core;
use core::ops::{Index, IndexMut, Range, RangeTo, RangeFrom, RangeFull}; use core::ops::{Index, IndexMut, Range, RangeTo, RangeFrom, RangeFull};

View File

@ -8,13 +8,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
// Tests the range assertion wraparound case when reading discriminants.
// this is for the wrapping_add call below.
#![feature(core)]
/*!
* Tests the range assertion wraparound case when reading discriminants.
*/
#[repr(u8)] #[repr(u8)]
#[derive(Copy, Clone)] #[derive(Copy, Clone)]

View File

@ -10,8 +10,6 @@
// pretty-expanded FIXME #23616 // pretty-expanded FIXME #23616
#![feature(core)]
trait U {} trait U {}
trait T<X: U> { fn get(self) -> X; } trait T<X: U> { fn get(self) -> X; }

View File

@ -12,8 +12,6 @@
// pretty-expanded FIXME #23616 // pretty-expanded FIXME #23616
#![feature(core)]
use std::cmp::PartialOrd; use std::cmp::PartialOrd;
pub trait NumCast: Sized { pub trait NumCast: Sized {

View File

@ -11,9 +11,6 @@
// Test that type IDs correctly account for higher-rank lifetimes // Test that type IDs correctly account for higher-rank lifetimes
// Also acts as a regression test for an ICE (issue #19791) // Also acts as a regression test for an ICE (issue #19791)
#![feature(core)]
use std::any::{Any, TypeId}; use std::any::{Any, TypeId};
struct Struct<'a>(&'a ()); struct Struct<'a>(&'a ());

View File

@ -7,9 +7,6 @@
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
//
#![feature(core)]
use std::str; use std::str;

View File

@ -13,9 +13,7 @@
// us from approximating the lifetimes of `field1` and `field2` to a // us from approximating the lifetimes of `field1` and `field2` to a
// common intersection. // common intersection.
#![allow(dead_code)] #![allow(dead_code)]
#![feature(core)]
struct List<'l> { struct List<'l> {
field1: &'l i32, field1: &'l i32,

View File

@ -10,9 +10,7 @@
// Test that vec is now covariant in its argument type. // Test that vec is now covariant in its argument type.
#![allow(dead_code)] #![allow(dead_code)]
#![feature(core)]
fn foo<'a,'b>(v1: Vec<&'a i32>, v2: Vec<&'b i32>) -> i32 { fn foo<'a,'b>(v1: Vec<&'a i32>, v2: Vec<&'b i32>) -> i32 {
bar(v1, v2).cloned().unwrap_or(0) // only type checks if we can intersect 'a and 'b bar(v1, v2).cloned().unwrap_or(0) // only type checks if we can intersect 'a and 'b

View File

@ -9,7 +9,6 @@
// except according to those terms. // except according to those terms.
#![feature(optin_builtin_traits)] #![feature(optin_builtin_traits)]
#![feature(core)]
pub mod bar { pub mod bar {
use std::marker; use std::marker;

View File

@ -14,7 +14,6 @@
//! (#14132). //! (#14132).
#![crate_name = "a"] #![crate_name = "a"]
#![feature(core)]
macro_rules! three { macro_rules! three {
() => { 3 } () => { 3 }