Skip to content

Commit b44cb01

Browse files
committed
Don't use std in stability tests
1 parent 1599c16 commit b44cb01

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

src/test/compile-fail/issue-28075.rs

+7-3
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,16 @@
1010

1111
// Unstable entities should be caught in import lists
1212

13+
// aux-build:lint_stability.rs
14+
1315
#![allow(unused_imports)]
1416

15-
use std::thread::{catch_panic, ScopedKey}; //~ ERROR use of unstable library feature 'catch_panic'
16-
//~^ ERROR use of unstable library feature 'scoped_tls'
17+
extern crate lint_stability;
18+
19+
use lint_stability::{unstable, deprecated}; //~ ERROR use of unstable library feature 'test_feature'
20+
//~^ WARNING use of deprecated item
1721

18-
use std::rt::{self}; //~ ERROR use of unstable library feature 'rt'
22+
use lint_stability::unstable::{self as u}; //~ ERROR use of unstable library feature 'test_feature'
1923

2024
fn main() {
2125
}

src/test/compile-fail/issue-28388-3.rs

+6-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,11 @@
1010

1111
// Prefix in imports with empty braces should be resolved and checked privacy, stability, etc.
1212

13-
use std::rt::{}; //~ ERROR use of unstable library feature 'rt'
14-
use std::{}; // OK
13+
// aux-build:lint_stability.rs
14+
15+
extern crate lint_stability;
16+
17+
use lint_stability::UnstableStruct::{}; //~ ERROR use of unstable library feature 'test_feature'
18+
use lint_stability::StableStruct::{}; // OK
1519

1620
fn main() {}

0 commit comments

Comments
 (0)