Skip to content

Commit c157ec8

Browse files
committed
Fix 2018 edition tests
1 parent 5815a84 commit c157ec8

20 files changed

+11
-42
lines changed

src/libcore/tests/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
#![feature(core_private_bignum)]
1414
#![feature(core_private_diy_float)]
1515
#![feature(dec2flt)]
16-
#![feature(decode_utf8)]
1716
#![feature(euclidean_division)]
1817
#![feature(exact_size_is_empty)]
1918
#![feature(fixed_size_array)]

src/libsyntax/diagnostic_list.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ the current edition.
381381
Erroneous code example:
382382
383383
```compile_fail,E0705
384-
#![allow(rust_2018_preview)]
384+
#![feature(rust_2018_preview)]
385385
#![feature(raw_identifiers)] // error: the feature `raw_identifiers` is
386386
// included in the Rust 2018 edition
387387
```

src/test/compile-fail/rfc-2126-extern-absolute-paths/non-existent-1.rs

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

1111
// edition:2018
1212

13-
#![feature(extern_absolute_paths)]
14-
1513
use xcrate::S; //~ ERROR can't find crate for `xcrate`
1614

1715
fn main() {}

src/test/compile-fail/rfc-2126-extern-absolute-paths/non-existent-2.rs

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

1111
// edition:2018
1212

13-
#![feature(extern_absolute_paths)]
14-
1513
fn main() {
1614
let s = ::xcrate::S; //~ ERROR can't find crate for `xcrate`
1715
}

src/test/compile-fail/rfc-2126-extern-absolute-paths/non-existent-3.rs

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

1111
// edition:2018
1212

13-
#![feature(extern_absolute_paths)]
14-
1513
use ycrate; //~ ERROR can't find crate for `ycrate`
1614

1715
fn main() {}

src/test/compile-fail/rfc-2126-extern-absolute-paths/single-segment.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@
1111
// aux-build:xcrate.rs
1212
// edition:2018
1313

14-
#![feature(crate_in_paths)]
15-
#![feature(extern_absolute_paths)]
16-
1714
use crate; //~ ERROR unresolved import `crate`
1815
//~^ NOTE crate root imports need to be explicitly named: `use crate as name;`
1916
use *; //~ ERROR unresolved import `*`

src/test/run-make-fulldeps/save-analysis-rfc2126/extern_absolute_paths.rs

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

11-
#![feature(extern_absolute_paths)]
12-
1311
use krate2::hello;
1412

1513
fn main() {

src/test/run-pass/auxiliary/edition-kw-macro-2018.rs

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

1111
// edition:2018
1212

13-
#![feature(raw_identifiers)]
14-
1513
#[macro_export]
1614
macro_rules! produces_async {
1715
() => (pub fn async() {})

src/test/run-pass/edition-keywords-2018-2015.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
// edition:2018
1212
// aux-build:edition-kw-macro-2015.rs
1313

14-
#![feature(raw_identifiers)]
15-
1614
#[macro_use]
1715
extern crate edition_kw_macro_2015;
1816

src/test/run-pass/edition-keywords-2018-2018.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
// edition:2018
1212
// aux-build:edition-kw-macro-2018.rs
1313

14-
#![feature(raw_identifiers)]
15-
1614
#[macro_use]
1715
extern crate edition_kw_macro_2018;
1816

src/test/run-pass/rfc-2126-extern-absolute-paths/basic.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
// aux-build:xcrate.rs
1212
// edition:2018
1313

14-
#![feature(extern_absolute_paths)]
15-
1614
use xcrate::Z;
1715

1816
fn f() {

src/test/run-pass/rfc-2126-extern-absolute-paths/test.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,5 @@
1515
// edition:2018
1616
// compile-flags: --test
1717

18-
#![feature(extern_absolute_paths)]
19-
2018
#[test]
21-
fn test() {
22-
}
19+
fn test() {}

src/test/ui/auxiliary/edition-kw-macro-2018.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010

1111
// edition:2018
1212

13-
#![feature(raw_identifiers)]
1413
#![allow(async_idents)]
1514

1615
#[macro_export]

src/test/ui/edition-keywords-2018-2015-expansion.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
// aux-build:edition-kw-macro-2015.rs
1313
// compile-pass
1414

15-
#![feature(raw_identifiers)]
1615
#![allow(async_idents)]
1716

1817
#[macro_use]

src/test/ui/edition-keywords-2018-2015-parsing.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
// edition:2018
1212
// aux-build:edition-kw-macro-2015.rs
1313

14-
#![feature(raw_identifiers)]
15-
1614
#[macro_use]
1715
extern crate edition_kw_macro_2015;
1816

src/test/ui/edition-keywords-2018-2015-parsing.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
error: expected identifier, found reserved keyword `async`
2-
--> $DIR/edition-keywords-2018-2015-parsing.rs:20:13
2+
--> $DIR/edition-keywords-2018-2015-parsing.rs:18:13
33
|
44
LL | let mut async = 1; //~ ERROR expected identifier, found reserved keyword `async`
55
| ^^^^^ expected identifier, found reserved keyword
66

77
error: expected identifier, found reserved keyword `async`
8-
--> $DIR/edition-keywords-2018-2015-parsing.rs:30:13
8+
--> $DIR/edition-keywords-2018-2015-parsing.rs:28:13
99
|
1010
LL | module::async(); //~ ERROR expected identifier, found reserved keyword `async`
1111
| ^^^^^ expected identifier, found reserved keyword
1212

1313
error: no rules expected the token `r#async`
14-
--> $DIR/edition-keywords-2018-2015-parsing.rs:24:31
14+
--> $DIR/edition-keywords-2018-2015-parsing.rs:22:31
1515
|
1616
LL | r#async = consumes_async!(r#async); //~ ERROR no rules expected the token `r#async`
1717
| ^^^^^^^
1818

1919
error: no rules expected the token `async`
20-
--> $DIR/edition-keywords-2018-2015-parsing.rs:25:35
20+
--> $DIR/edition-keywords-2018-2015-parsing.rs:23:35
2121
|
2222
LL | r#async = consumes_async_raw!(async); //~ ERROR no rules expected the token `async`
2323
| ^^^^^

src/test/ui/edition-keywords-2018-2018-expansion.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
// edition:2018
1212
// aux-build:edition-kw-macro-2018.rs
1313

14-
#![feature(raw_identifiers)]
15-
1614
#[macro_use]
1715
extern crate edition_kw_macro_2018;
1816

src/test/ui/edition-keywords-2018-2018-expansion.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error: expected identifier, found reserved keyword `async`
2-
--> $DIR/edition-keywords-2018-2018-expansion.rs:20:5
2+
--> $DIR/edition-keywords-2018-2018-expansion.rs:18:5
33
|
44
LL | produces_async! {} //~ ERROR expected identifier, found reserved keyword `async`
55
| ^^^^^^^^^^^^^^^^^^ expected identifier, found reserved keyword

src/test/ui/edition-keywords-2018-2018-parsing.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
// edition:2018
1212
// aux-build:edition-kw-macro-2018.rs
1313

14-
#![feature(raw_identifiers)]
15-
1614
#[macro_use]
1715
extern crate edition_kw_macro_2018;
1816

src/test/ui/edition-keywords-2018-2018-parsing.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
11
error: expected identifier, found reserved keyword `async`
2-
--> $DIR/edition-keywords-2018-2018-parsing.rs:20:13
2+
--> $DIR/edition-keywords-2018-2018-parsing.rs:18:13
33
|
44
LL | let mut async = 1; //~ ERROR expected identifier, found reserved keyword `async`
55
| ^^^^^ expected identifier, found reserved keyword
66

77
error: expected identifier, found reserved keyword `async`
8-
--> $DIR/edition-keywords-2018-2018-parsing.rs:30:13
8+
--> $DIR/edition-keywords-2018-2018-parsing.rs:28:13
99
|
1010
LL | module::async(); //~ ERROR expected identifier, found reserved keyword `async`
1111
| ^^^^^ expected identifier, found reserved keyword
1212

1313
error: no rules expected the token `r#async`
14-
--> $DIR/edition-keywords-2018-2018-parsing.rs:24:31
14+
--> $DIR/edition-keywords-2018-2018-parsing.rs:22:31
1515
|
1616
LL | r#async = consumes_async!(r#async); //~ ERROR no rules expected the token `r#async`
1717
| ^^^^^^^
1818

1919
error: no rules expected the token `async`
20-
--> $DIR/edition-keywords-2018-2018-parsing.rs:25:35
20+
--> $DIR/edition-keywords-2018-2018-parsing.rs:23:35
2121
|
2222
LL | r#async = consumes_async_raw!(async); //~ ERROR no rules expected the token `async`
2323
| ^^^^^

0 commit comments

Comments
 (0)