summaryrefslogtreecommitdiffstats
path: root/src/test/ui/editions
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/editions')
-rw-r--r--src/test/ui/editions/async-block-2015.rs30
-rw-r--r--src/test/ui/editions/async-block-2015.stderr41
-rw-r--r--src/test/ui/editions/auxiliary/absolute.rs1
-rw-r--r--src/test/ui/editions/auxiliary/edition-extern-crate-allowed.rs1
-rw-r--r--src/test/ui/editions/auxiliary/edition-imports-2015.rs31
-rw-r--r--src/test/ui/editions/auxiliary/edition-imports-2018.rs17
-rw-r--r--src/test/ui/editions/auxiliary/edition-kw-macro-2015.rs28
-rw-r--r--src/test/ui/editions/auxiliary/edition-kw-macro-2018.rs28
-rw-r--r--src/test/ui/editions/dyn-trait-sugg-2021.rs12
-rw-r--r--src/test/ui/editions/dyn-trait-sugg-2021.stderr14
-rw-r--r--src/test/ui/editions/edition-extern-crate-allowed.rs10
-rw-r--r--src/test/ui/editions/edition-extern-crate-allowed.stderr15
-rw-r--r--src/test/ui/editions/edition-feature-ok.rs5
-rw-r--r--src/test/ui/editions/edition-feature-redundant.rs7
-rw-r--r--src/test/ui/editions/edition-feature-redundant.stderr9
-rw-r--r--src/test/ui/editions/edition-imports-2015.rs26
-rw-r--r--src/test/ui/editions/edition-imports-2015.stderr10
-rw-r--r--src/test/ui/editions/edition-imports-2018.rs27
-rw-r--r--src/test/ui/editions/edition-imports-2018.stderr10
-rw-r--r--src/test/ui/editions/edition-imports-virtual-2015-ambiguity.rs20
-rw-r--r--src/test/ui/editions/edition-imports-virtual-2015-gated.rs11
-rw-r--r--src/test/ui/editions/edition-imports-virtual-2015-gated.stderr11
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2015-expansion.rs17
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2015-parsing.rs26
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2015-parsing.stderr26
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2015.rs36
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2018-expansion.rs14
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2018-expansion.stderr15
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2018-parsing.rs26
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2018-parsing.stderr26
-rw-r--r--src/test/ui/editions/edition-keywords-2015-2018.rs36
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2015-expansion.rs17
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2015-parsing.rs30
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2015-parsing.stderr68
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2015.rs34
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2018-expansion.rs14
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2018-expansion.stderr15
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2018-parsing.rs30
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2018-parsing.stderr68
-rw-r--r--src/test/ui/editions/edition-keywords-2018-2018.rs34
-rw-r--r--src/test/ui/editions/edition-raw-pointer-method-2015.rs12
-rw-r--r--src/test/ui/editions/edition-raw-pointer-method-2015.stderr17
-rw-r--r--src/test/ui/editions/edition-raw-pointer-method-2018.rs11
-rw-r--r--src/test/ui/editions/edition-raw-pointer-method-2018.stderr9
-rw-r--r--src/test/ui/editions/epoch-gate-feature.rs15
45 files changed, 0 insertions, 960 deletions
diff --git a/src/test/ui/editions/async-block-2015.rs b/src/test/ui/editions/async-block-2015.rs
deleted file mode 100644
index 3daf4930c..000000000
--- a/src/test/ui/editions/async-block-2015.rs
+++ /dev/null
@@ -1,30 +0,0 @@
-async fn foo() {
-//~^ ERROR `async fn` is not permitted in Rust 2015
-//~| NOTE to use `async fn`, switch to Rust 2018 or later
-//~| HELP pass `--edition 2021` to `rustc`
-//~| NOTE for more on editions, read https://doc.rust-lang.org/edition-guide
-
- let x = async {};
- //~^ ERROR cannot find struct, variant or union type `async` in this scope
- //~| NOTE `async` blocks are only allowed in Rust 2018 or later
- let y = async { //~ NOTE `async` blocks are only allowed in Rust 2018 or later
- let x = 42;
- //~^ ERROR expected identifier, found keyword `let`
- //~| NOTE expected identifier, found keyword
- //~| HELP pass `--edition 2021` to `rustc`
- //~| NOTE for more on editions, read https://doc.rust-lang.org/edition-guide
- 42
- };
- let z = async { //~ NOTE `async` blocks are only allowed in Rust 2018 or later
- 42
- //~^ ERROR expected identifier, found `42`
- //~| NOTE expected identifier
- //~| HELP pass `--edition 2021` to `rustc`
- //~| NOTE for more on editions, read https://doc.rust-lang.org/edition-guide
- };
- y.await;
- z.await;
- x
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/async-block-2015.stderr b/src/test/ui/editions/async-block-2015.stderr
deleted file mode 100644
index b792b8c1e..000000000
--- a/src/test/ui/editions/async-block-2015.stderr
+++ /dev/null
@@ -1,41 +0,0 @@
-error[E0670]: `async fn` is not permitted in Rust 2015
- --> $DIR/async-block-2015.rs:1:1
- |
-LL | async fn foo() {
- | ^^^^^ to use `async fn`, switch to Rust 2018 or later
- |
- = help: pass `--edition 2021` to `rustc`
- = note: for more on editions, read https://doc.rust-lang.org/edition-guide
-
-error: expected identifier, found keyword `let`
- --> $DIR/async-block-2015.rs:11:9
- |
-LL | let y = async {
- | ----- `async` blocks are only allowed in Rust 2018 or later
-LL | let x = 42;
- | ^^^ expected identifier, found keyword
- |
- = help: pass `--edition 2021` to `rustc`
- = note: for more on editions, read https://doc.rust-lang.org/edition-guide
-
-error: expected identifier, found `42`
- --> $DIR/async-block-2015.rs:19:9
- |
-LL | let z = async {
- | ----- `async` blocks are only allowed in Rust 2018 or later
-LL | 42
- | ^^ expected identifier
- |
- = help: pass `--edition 2021` to `rustc`
- = note: for more on editions, read https://doc.rust-lang.org/edition-guide
-
-error[E0422]: cannot find struct, variant or union type `async` in this scope
- --> $DIR/async-block-2015.rs:7:13
- |
-LL | let x = async {};
- | ^^^^^ `async` blocks are only allowed in Rust 2018 or later
-
-error: aborting due to 4 previous errors
-
-Some errors have detailed explanations: E0422, E0670.
-For more information about an error, try `rustc --explain E0422`.
diff --git a/src/test/ui/editions/auxiliary/absolute.rs b/src/test/ui/editions/auxiliary/absolute.rs
deleted file mode 100644
index d596f9735..000000000
--- a/src/test/ui/editions/auxiliary/absolute.rs
+++ /dev/null
@@ -1 +0,0 @@
-pub struct Path;
diff --git a/src/test/ui/editions/auxiliary/edition-extern-crate-allowed.rs b/src/test/ui/editions/auxiliary/edition-extern-crate-allowed.rs
deleted file mode 100644
index d11c69f81..000000000
--- a/src/test/ui/editions/auxiliary/edition-extern-crate-allowed.rs
+++ /dev/null
@@ -1 +0,0 @@
-// intentionally empty
diff --git a/src/test/ui/editions/auxiliary/edition-imports-2015.rs b/src/test/ui/editions/auxiliary/edition-imports-2015.rs
deleted file mode 100644
index c72331ca2..000000000
--- a/src/test/ui/editions/auxiliary/edition-imports-2015.rs
+++ /dev/null
@@ -1,31 +0,0 @@
-// edition:2015
-
-#[macro_export]
-macro_rules! gen_imports { () => {
- use import::Path;
- use std::collections::LinkedList;
-
- fn check_absolute() {
- ::absolute::Path;
- ::std::collections::LinkedList::<u8>::new();
- }
-}}
-
-#[macro_export]
-macro_rules! gen_glob { () => {
- use *;
-}}
-
-#[macro_export]
-macro_rules! gen_gated { () => {
- fn check_gated() {
- enum E { A }
- use E::*;
- }
-}}
-
-#[macro_export]
-macro_rules! gen_ambiguous { () => {
- use Ambiguous;
- type A = ::edition_imports_2015::Path;
-}}
diff --git a/src/test/ui/editions/auxiliary/edition-imports-2018.rs b/src/test/ui/editions/auxiliary/edition-imports-2018.rs
deleted file mode 100644
index b08dc499a..000000000
--- a/src/test/ui/editions/auxiliary/edition-imports-2018.rs
+++ /dev/null
@@ -1,17 +0,0 @@
-// edition:2018
-
-#[macro_export]
-macro_rules! gen_imports { () => {
- use import::Path;
- use std::collections::LinkedList;
-
- fn check_absolute() {
- ::absolute::Path;
- ::std::collections::LinkedList::<u8>::new();
- }
-}}
-
-#[macro_export]
-macro_rules! gen_glob { () => {
- use *;
-}}
diff --git a/src/test/ui/editions/auxiliary/edition-kw-macro-2015.rs b/src/test/ui/editions/auxiliary/edition-kw-macro-2015.rs
deleted file mode 100644
index 7cfd128f2..000000000
--- a/src/test/ui/editions/auxiliary/edition-kw-macro-2015.rs
+++ /dev/null
@@ -1,28 +0,0 @@
-// edition:2015
-
-#![allow(keyword_idents)]
-
-#[macro_export]
-macro_rules! produces_async {
- () => (pub fn async() {})
-}
-
-#[macro_export]
-macro_rules! produces_async_raw {
- () => (pub fn r#async() {})
-}
-
-#[macro_export]
-macro_rules! consumes_async {
- (async) => (1)
-}
-
-#[macro_export]
-macro_rules! consumes_async_raw {
- (r#async) => (1)
-}
-
-#[macro_export]
-macro_rules! passes_ident {
- ($i: ident) => ($i)
-}
diff --git a/src/test/ui/editions/auxiliary/edition-kw-macro-2018.rs b/src/test/ui/editions/auxiliary/edition-kw-macro-2018.rs
deleted file mode 100644
index d07c0218d..000000000
--- a/src/test/ui/editions/auxiliary/edition-kw-macro-2018.rs
+++ /dev/null
@@ -1,28 +0,0 @@
-// edition:2018
-
-#![allow(keyword_idents)]
-
-#[macro_export]
-macro_rules! produces_async {
- () => (pub fn async() {})
-}
-
-#[macro_export]
-macro_rules! produces_async_raw {
- () => (pub fn r#async() {})
-}
-
-#[macro_export]
-macro_rules! consumes_async {
- (async) => (1)
-}
-
-#[macro_export]
-macro_rules! consumes_async_raw {
- (r#async) => (1)
-}
-
-#[macro_export]
-macro_rules! passes_ident {
- ($i: ident) => ($i)
-}
diff --git a/src/test/ui/editions/dyn-trait-sugg-2021.rs b/src/test/ui/editions/dyn-trait-sugg-2021.rs
deleted file mode 100644
index de0444b63..000000000
--- a/src/test/ui/editions/dyn-trait-sugg-2021.rs
+++ /dev/null
@@ -1,12 +0,0 @@
-// edition:2021
-
-trait Foo<T> {}
-
-impl<T> dyn Foo<T> {
- fn hi(_x: T) {}
-}
-
-fn main() {
- Foo::hi(123);
- //~^ ERROR trait objects must include the `dyn` keyword
-}
diff --git a/src/test/ui/editions/dyn-trait-sugg-2021.stderr b/src/test/ui/editions/dyn-trait-sugg-2021.stderr
deleted file mode 100644
index 8c68dec1d..000000000
--- a/src/test/ui/editions/dyn-trait-sugg-2021.stderr
+++ /dev/null
@@ -1,14 +0,0 @@
-error[E0782]: trait objects must include the `dyn` keyword
- --> $DIR/dyn-trait-sugg-2021.rs:10:5
- |
-LL | Foo::hi(123);
- | ^^^
- |
-help: add `dyn` keyword before this trait
- |
-LL | <dyn Foo>::hi(123);
- | ++++ +
-
-error: aborting due to previous error
-
-For more information about this error, try `rustc --explain E0782`.
diff --git a/src/test/ui/editions/edition-extern-crate-allowed.rs b/src/test/ui/editions/edition-extern-crate-allowed.rs
deleted file mode 100644
index 8d142cea5..000000000
--- a/src/test/ui/editions/edition-extern-crate-allowed.rs
+++ /dev/null
@@ -1,10 +0,0 @@
-// aux-build:edition-extern-crate-allowed.rs
-// edition:2015
-// check-pass
-
-#![warn(rust_2018_idioms)]
-
-extern crate edition_extern_crate_allowed;
-//~^ WARNING unused extern crate
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-extern-crate-allowed.stderr b/src/test/ui/editions/edition-extern-crate-allowed.stderr
deleted file mode 100644
index dde774c52..000000000
--- a/src/test/ui/editions/edition-extern-crate-allowed.stderr
+++ /dev/null
@@ -1,15 +0,0 @@
-warning: unused extern crate
- --> $DIR/edition-extern-crate-allowed.rs:7:1
- |
-LL | extern crate edition_extern_crate_allowed;
- | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it
- |
-note: the lint level is defined here
- --> $DIR/edition-extern-crate-allowed.rs:5:9
- |
-LL | #![warn(rust_2018_idioms)]
- | ^^^^^^^^^^^^^^^^
- = note: `#[warn(unused_extern_crates)]` implied by `#[warn(rust_2018_idioms)]`
-
-warning: 1 warning emitted
-
diff --git a/src/test/ui/editions/edition-feature-ok.rs b/src/test/ui/editions/edition-feature-ok.rs
deleted file mode 100644
index 69242fd71..000000000
--- a/src/test/ui/editions/edition-feature-ok.rs
+++ /dev/null
@@ -1,5 +0,0 @@
-// check-pass
-
-#![feature(rust_2018_preview)]
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-feature-redundant.rs b/src/test/ui/editions/edition-feature-redundant.rs
deleted file mode 100644
index 1049a2da8..000000000
--- a/src/test/ui/editions/edition-feature-redundant.rs
+++ /dev/null
@@ -1,7 +0,0 @@
-// edition:2018
-// check-pass
-
-#![feature(rust_2018_preview)]
-//~^ WARN the feature `rust_2018_preview` is included in the Rust 2018 edition
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-feature-redundant.stderr b/src/test/ui/editions/edition-feature-redundant.stderr
deleted file mode 100644
index b11e616d7..000000000
--- a/src/test/ui/editions/edition-feature-redundant.stderr
+++ /dev/null
@@ -1,9 +0,0 @@
-warning[E0705]: the feature `rust_2018_preview` is included in the Rust 2018 edition
- --> $DIR/edition-feature-redundant.rs:4:12
- |
-LL | #![feature(rust_2018_preview)]
- | ^^^^^^^^^^^^^^^^^
-
-warning: 1 warning emitted
-
-For more information about this error, try `rustc --explain E0705`.
diff --git a/src/test/ui/editions/edition-imports-2015.rs b/src/test/ui/editions/edition-imports-2015.rs
deleted file mode 100644
index 5ba45b19d..000000000
--- a/src/test/ui/editions/edition-imports-2015.rs
+++ /dev/null
@@ -1,26 +0,0 @@
-// edition:2015
-// compile-flags:--extern absolute
-// aux-build:edition-imports-2018.rs
-// aux-build:absolute.rs
-
-#[macro_use]
-extern crate edition_imports_2018;
-
-mod check {
- mod import {
- pub struct Path;
- }
-
- gen_imports!(); // OK
-
- fn check() {
- Path;
- LinkedList::<u8>::new();
- }
-}
-
-mod check_glob {
- gen_glob!(); //~ ERROR cannot glob-import all possible crates
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-imports-2015.stderr b/src/test/ui/editions/edition-imports-2015.stderr
deleted file mode 100644
index 3f38e6f8e..000000000
--- a/src/test/ui/editions/edition-imports-2015.stderr
+++ /dev/null
@@ -1,10 +0,0 @@
-error: cannot glob-import all possible crates
- --> $DIR/edition-imports-2015.rs:23:5
- |
-LL | gen_glob!();
- | ^^^^^^^^^^^
- |
- = note: this error originates in the macro `gen_glob` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: aborting due to previous error
-
diff --git a/src/test/ui/editions/edition-imports-2018.rs b/src/test/ui/editions/edition-imports-2018.rs
deleted file mode 100644
index dcdbf0d05..000000000
--- a/src/test/ui/editions/edition-imports-2018.rs
+++ /dev/null
@@ -1,27 +0,0 @@
-// edition:2018
-// aux-build:edition-imports-2015.rs
-
-#[macro_use]
-extern crate edition_imports_2015;
-
-mod import {
- pub struct Path;
-}
-mod absolute {
- pub struct Path;
-}
-
-mod check {
- gen_imports!(); // OK
-
- fn check() {
- Path;
- LinkedList::<u8>::new();
- }
-}
-
-mod check_glob {
- gen_glob!(); //~ ERROR cannot glob-import all possible crates
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-imports-2018.stderr b/src/test/ui/editions/edition-imports-2018.stderr
deleted file mode 100644
index e7f760e49..000000000
--- a/src/test/ui/editions/edition-imports-2018.stderr
+++ /dev/null
@@ -1,10 +0,0 @@
-error: cannot glob-import all possible crates
- --> $DIR/edition-imports-2018.rs:24:5
- |
-LL | gen_glob!();
- | ^^^^^^^^^^^
- |
- = note: this error originates in the macro `gen_glob` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: aborting due to previous error
-
diff --git a/src/test/ui/editions/edition-imports-virtual-2015-ambiguity.rs b/src/test/ui/editions/edition-imports-virtual-2015-ambiguity.rs
deleted file mode 100644
index 3fffb30c6..000000000
--- a/src/test/ui/editions/edition-imports-virtual-2015-ambiguity.rs
+++ /dev/null
@@ -1,20 +0,0 @@
-// check-pass
-// edition:2018
-// compile-flags:--extern edition_imports_2015
-// aux-build:edition-imports-2015.rs
-
-mod edition_imports_2015 {
- pub struct Path;
-}
-
-pub struct Ambiguous {}
-
-mod check {
- pub struct Ambiguous {}
-
- fn check() {
- edition_imports_2015::gen_ambiguous!(); // OK
- }
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-imports-virtual-2015-gated.rs b/src/test/ui/editions/edition-imports-virtual-2015-gated.rs
deleted file mode 100644
index 634d3e9a4..000000000
--- a/src/test/ui/editions/edition-imports-virtual-2015-gated.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-// edition:2018
-// aux-build:edition-imports-2015.rs
-
-#[macro_use]
-extern crate edition_imports_2015;
-
-mod check {
- gen_gated!(); //~ ERROR unresolved import `E`
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-imports-virtual-2015-gated.stderr b/src/test/ui/editions/edition-imports-virtual-2015-gated.stderr
deleted file mode 100644
index e4bdd2821..000000000
--- a/src/test/ui/editions/edition-imports-virtual-2015-gated.stderr
+++ /dev/null
@@ -1,11 +0,0 @@
-error[E0432]: unresolved import `E`
- --> $DIR/edition-imports-virtual-2015-gated.rs:8:5
- |
-LL | gen_gated!();
- | ^^^^^^^^^^^^ could not find `E` in the list of imported crates
- |
- = note: this error originates in the macro `gen_gated` (in Nightly builds, run with -Z macro-backtrace for more info)
-
-error: aborting due to previous error
-
-For more information about this error, try `rustc --explain E0432`.
diff --git a/src/test/ui/editions/edition-keywords-2015-2015-expansion.rs b/src/test/ui/editions/edition-keywords-2015-2015-expansion.rs
deleted file mode 100644
index b2695bea5..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2015-expansion.rs
+++ /dev/null
@@ -1,17 +0,0 @@
-// edition:2015
-// aux-build:edition-kw-macro-2015.rs
-// check-pass
-
-#![allow(keyword_idents)]
-
-#[macro_use]
-extern crate edition_kw_macro_2015;
-
-mod one_async {
- produces_async! {} // OK
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2015-2015-parsing.rs b/src/test/ui/editions/edition-keywords-2015-2015-parsing.rs
deleted file mode 100644
index d1752a7ec..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2015-parsing.rs
+++ /dev/null
@@ -1,26 +0,0 @@
-// edition:2015
-// aux-build:edition-kw-macro-2015.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2015;
-
-mod module {
- pub fn async() {}
-}
-
-pub fn check_async() {
- let mut async = 1; // OK
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- r#async = consumes_async!(r#async); //~ ERROR no rules expected the token `r#async`
- r#async = consumes_async_raw!(async); //~ ERROR no rules expected the token `async`
- r#async = consumes_async_raw!(r#async); // OK
-
- if passes_ident!(async) == 1 {} // OK
- if passes_ident!(r#async) == 1 {} // OK
- module::async(); // OK
- module::r#async(); // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2015-2015-parsing.stderr b/src/test/ui/editions/edition-keywords-2015-2015-parsing.stderr
deleted file mode 100644
index 39944622d..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2015-parsing.stderr
+++ /dev/null
@@ -1,26 +0,0 @@
-error: no rules expected the token `r#async`
- --> $DIR/edition-keywords-2015-2015-parsing.rs:16:31
- |
-LL | r#async = consumes_async!(r#async);
- | ^^^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `async`
- --> $DIR/auxiliary/edition-kw-macro-2015.rs:17:6
- |
-LL | (async) => (1)
- | ^^^^^
-
-error: no rules expected the token `async`
- --> $DIR/edition-keywords-2015-2015-parsing.rs:17:35
- |
-LL | r#async = consumes_async_raw!(async);
- | ^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `r#async`
- --> $DIR/auxiliary/edition-kw-macro-2015.rs:22:6
- |
-LL | (r#async) => (1)
- | ^^^^^^^
-
-error: aborting due to 2 previous errors
-
diff --git a/src/test/ui/editions/edition-keywords-2015-2015.rs b/src/test/ui/editions/edition-keywords-2015-2015.rs
deleted file mode 100644
index 943d203b8..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2015.rs
+++ /dev/null
@@ -1,36 +0,0 @@
-// run-pass
-
-#![allow(unused_mut)]
-#![allow(unused_assignments)]
-#![allow(unused_variables)]
-// edition:2015
-// aux-build:edition-kw-macro-2015.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2015;
-
-pub fn check_async() {
- let mut async = 1; // OK
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- // r#async = consumes_async!(r#async); // ERROR, not a match
- // r#async = consumes_async_raw!(async); // ERROR, not a match
- r#async = consumes_async_raw!(r#async); // OK
-
- if passes_ident!(async) == 1 {} // OK
- if passes_ident!(r#async) == 1 {} // OK
- one_async::async(); // OK
- one_async::r#async(); // OK
- two_async::async(); // OK
- two_async::r#async(); // OK
-}
-
-mod one_async {
- produces_async! {} // OK
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2015-2018-expansion.rs b/src/test/ui/editions/edition-keywords-2015-2018-expansion.rs
deleted file mode 100644
index 9f34a3887..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2018-expansion.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-// edition:2015
-// aux-build:edition-kw-macro-2018.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2018;
-
-mod one_async {
- produces_async! {} //~ ERROR expected identifier, found keyword
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2015-2018-expansion.stderr b/src/test/ui/editions/edition-keywords-2015-2018-expansion.stderr
deleted file mode 100644
index 570bbac2b..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2018-expansion.stderr
+++ /dev/null
@@ -1,15 +0,0 @@
-error: expected identifier, found keyword `async`
- --> $DIR/edition-keywords-2015-2018-expansion.rs:8:5
- |
-LL | produces_async! {}
- | ^^^^^^^^^^^^^^^^^^ expected identifier, found keyword
- |
- = note: this error originates in the macro `produces_async` (in Nightly builds, run with -Z macro-backtrace for more info)
-help: escape `async` to use it as an identifier
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:7:19
- |
-LL | () => (pub fn r#async() {})
- | ++
-
-error: aborting due to previous error
-
diff --git a/src/test/ui/editions/edition-keywords-2015-2018-parsing.rs b/src/test/ui/editions/edition-keywords-2015-2018-parsing.rs
deleted file mode 100644
index 44455f438..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2018-parsing.rs
+++ /dev/null
@@ -1,26 +0,0 @@
-// edition:2015
-// aux-build:edition-kw-macro-2018.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2018;
-
-mod module {
- pub fn async() {}
-}
-
-pub fn check_async() {
- let mut async = 1; // OK
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- r#async = consumes_async!(r#async); //~ ERROR no rules expected the token `r#async`
- r#async = consumes_async_raw!(async); //~ ERROR no rules expected the token `async`
- r#async = consumes_async_raw!(r#async); // OK
-
- if passes_ident!(async) == 1 {} // OK
- if passes_ident!(r#async) == 1 {} // OK
- module::async(); // OK
- module::r#async(); // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2015-2018-parsing.stderr b/src/test/ui/editions/edition-keywords-2015-2018-parsing.stderr
deleted file mode 100644
index fa83908e6..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2018-parsing.stderr
+++ /dev/null
@@ -1,26 +0,0 @@
-error: no rules expected the token `r#async`
- --> $DIR/edition-keywords-2015-2018-parsing.rs:16:31
- |
-LL | r#async = consumes_async!(r#async);
- | ^^^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `async`
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:17:6
- |
-LL | (async) => (1)
- | ^^^^^
-
-error: no rules expected the token `async`
- --> $DIR/edition-keywords-2015-2018-parsing.rs:17:35
- |
-LL | r#async = consumes_async_raw!(async);
- | ^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `r#async`
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:22:6
- |
-LL | (r#async) => (1)
- | ^^^^^^^
-
-error: aborting due to 2 previous errors
-
diff --git a/src/test/ui/editions/edition-keywords-2015-2018.rs b/src/test/ui/editions/edition-keywords-2015-2018.rs
deleted file mode 100644
index 8c3397c95..000000000
--- a/src/test/ui/editions/edition-keywords-2015-2018.rs
+++ /dev/null
@@ -1,36 +0,0 @@
-// run-pass
-
-#![allow(unused_mut)]
-#![allow(unused_assignments)]
-#![allow(unused_variables)]
-// edition:2015
-// aux-build:edition-kw-macro-2018.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2018;
-
-pub fn check_async() {
- let mut async = 1; // OK
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- // r#async = consumes_async!(r#async); // ERROR, not a match
- // r#async = consumes_async_raw!(async); // ERROR, not a match
- r#async = consumes_async_raw!(r#async); // OK
-
- if passes_ident!(async) == 1 {} // OK
- if passes_ident!(r#async) == 1 {} // OK
- // one_async::async(); // ERROR, unresolved name
- // one_async::r#async(); // ERROR, unresolved name
- two_async::async(); // OK
- two_async::r#async(); // OK
-}
-
-mod one_async {
- // produces_async! {} // ERROR, reserved
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2018-2015-expansion.rs b/src/test/ui/editions/edition-keywords-2018-2015-expansion.rs
deleted file mode 100644
index 707d8e95c..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2015-expansion.rs
+++ /dev/null
@@ -1,17 +0,0 @@
-// edition:2018
-// aux-build:edition-kw-macro-2015.rs
-// check-pass
-
-#![allow(keyword_idents)]
-
-#[macro_use]
-extern crate edition_kw_macro_2015;
-
-mod one_async {
- produces_async! {} // OK
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2018-2015-parsing.rs b/src/test/ui/editions/edition-keywords-2018-2015-parsing.rs
deleted file mode 100644
index d5ed9fb9a..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2015-parsing.rs
+++ /dev/null
@@ -1,30 +0,0 @@
-// edition:2018
-// aux-build:edition-kw-macro-2015.rs
-
-#![feature(async_closure)]
-
-fn main() {}
-
-#[macro_use]
-extern crate edition_kw_macro_2015;
-
-mod module {
- pub fn r#async() {}
-}
-
-pub fn check_async() {
- let mut async = 1; //~ ERROR expected identifier, found keyword `async`
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- r#async = consumes_async!(r#async); //~ ERROR no rules expected the token `r#async`
- r#async = consumes_async_raw!(async); //~ ERROR no rules expected the token `async`
- r#async = consumes_async_raw!(r#async); // OK
-
- if passes_ident!(async) == 1 {}
- if passes_ident!(r#async) == 1 {} // OK
- module::async(); //~ ERROR expected identifier, found keyword `async`
- module::r#async(); // OK
-
- let _recovery_witness: () = 0; //~ ERROR mismatched types
-}
diff --git a/src/test/ui/editions/edition-keywords-2018-2015-parsing.stderr b/src/test/ui/editions/edition-keywords-2018-2015-parsing.stderr
deleted file mode 100644
index 1a4a94e97..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2015-parsing.stderr
+++ /dev/null
@@ -1,68 +0,0 @@
-error: expected identifier, found keyword `async`
- --> $DIR/edition-keywords-2018-2015-parsing.rs:16:13
- |
-LL | let mut async = 1;
- | ^^^^^ expected identifier, found keyword
- |
-help: escape `async` to use it as an identifier
- |
-LL | let mut r#async = 1;
- | ++
-
-error: expected identifier, found keyword `async`
- --> $DIR/edition-keywords-2018-2015-parsing.rs:26:13
- |
-LL | module::async();
- | ^^^^^ expected identifier, found keyword
- |
-help: escape `async` to use it as an identifier
- |
-LL | module::r#async();
- | ++
-
-error: no rules expected the token `r#async`
- --> $DIR/edition-keywords-2018-2015-parsing.rs:20:31
- |
-LL | r#async = consumes_async!(r#async);
- | ^^^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `async`
- --> $DIR/auxiliary/edition-kw-macro-2015.rs:17:6
- |
-LL | (async) => (1)
- | ^^^^^
-
-error: no rules expected the token `async`
- --> $DIR/edition-keywords-2018-2015-parsing.rs:21:35
- |
-LL | r#async = consumes_async_raw!(async);
- | ^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `r#async`
- --> $DIR/auxiliary/edition-kw-macro-2015.rs:22:6
- |
-LL | (r#async) => (1)
- | ^^^^^^^
-
-error: macro expansion ends with an incomplete expression: expected one of `move`, `|`, or `||`
- --> $DIR/auxiliary/edition-kw-macro-2015.rs:27:23
- |
-LL | ($i: ident) => ($i)
- | ^ expected one of `move`, `|`, or `||`
- |
- ::: $DIR/edition-keywords-2018-2015-parsing.rs:24:8
- |
-LL | if passes_ident!(async) == 1 {}
- | -------------------- in this macro invocation
-
-error[E0308]: mismatched types
- --> $DIR/edition-keywords-2018-2015-parsing.rs:29:33
- |
-LL | let _recovery_witness: () = 0;
- | -- ^ expected `()`, found integer
- | |
- | expected due to this
-
-error: aborting due to 6 previous errors
-
-For more information about this error, try `rustc --explain E0308`.
diff --git a/src/test/ui/editions/edition-keywords-2018-2015.rs b/src/test/ui/editions/edition-keywords-2018-2015.rs
deleted file mode 100644
index 2cb2dfb18..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2015.rs
+++ /dev/null
@@ -1,34 +0,0 @@
-// run-pass
-
-#![allow(unused_assignments)]
-// edition:2018
-// aux-build:edition-kw-macro-2015.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2015;
-
-pub fn check_async() {
- // let mut async = 1; // ERROR, reserved
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- // r#async = consumes_async!(r#async); // ERROR, not a match
- // r#async = consumes_async_raw!(async); // ERROR, not a match
- r#async = consumes_async_raw!(r#async); // OK
-
- // if passes_ident!(async) == 1 {} // ERROR, reserved
- if passes_ident!(r#async) == 1 {} // OK
- // one_async::async(); // ERROR, reserved
- one_async::r#async(); // OK
- // two_async::async(); // ERROR, reserved
- two_async::r#async(); // OK
-}
-
-mod one_async {
- produces_async! {} // OK
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2018-2018-expansion.rs b/src/test/ui/editions/edition-keywords-2018-2018-expansion.rs
deleted file mode 100644
index a8e69fed6..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2018-expansion.rs
+++ /dev/null
@@ -1,14 +0,0 @@
-// edition:2018
-// aux-build:edition-kw-macro-2018.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2018;
-
-mod one_async {
- produces_async! {} //~ ERROR expected identifier, found keyword `async`
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-keywords-2018-2018-expansion.stderr b/src/test/ui/editions/edition-keywords-2018-2018-expansion.stderr
deleted file mode 100644
index 69f275746..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2018-expansion.stderr
+++ /dev/null
@@ -1,15 +0,0 @@
-error: expected identifier, found keyword `async`
- --> $DIR/edition-keywords-2018-2018-expansion.rs:8:5
- |
-LL | produces_async! {}
- | ^^^^^^^^^^^^^^^^^^ expected identifier, found keyword
- |
- = note: this error originates in the macro `produces_async` (in Nightly builds, run with -Z macro-backtrace for more info)
-help: escape `async` to use it as an identifier
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:7:19
- |
-LL | () => (pub fn r#async() {})
- | ++
-
-error: aborting due to previous error
-
diff --git a/src/test/ui/editions/edition-keywords-2018-2018-parsing.rs b/src/test/ui/editions/edition-keywords-2018-2018-parsing.rs
deleted file mode 100644
index 044ab249f..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2018-parsing.rs
+++ /dev/null
@@ -1,30 +0,0 @@
-// edition:2018
-// aux-build:edition-kw-macro-2018.rs
-
-#![feature(async_closure)]
-
-fn main() {}
-
-#[macro_use]
-extern crate edition_kw_macro_2018;
-
-mod module {
- pub fn r#async() {}
-}
-
-pub fn check_async() {
- let mut async = 1; //~ ERROR expected identifier, found keyword `async`
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- r#async = consumes_async!(r#async); //~ ERROR no rules expected the token `r#async`
- r#async = consumes_async_raw!(async); //~ ERROR no rules expected the token `async`
- r#async = consumes_async_raw!(r#async); // OK
-
- if passes_ident!(async) == 1 {}
- if passes_ident!(r#async) == 1 {} // OK
- module::async(); //~ ERROR expected identifier, found keyword `async`
- module::r#async(); // OK
-
- let _recovery_witness: () = 0; //~ ERROR mismatched types
-}
diff --git a/src/test/ui/editions/edition-keywords-2018-2018-parsing.stderr b/src/test/ui/editions/edition-keywords-2018-2018-parsing.stderr
deleted file mode 100644
index 19eb7ac98..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2018-parsing.stderr
+++ /dev/null
@@ -1,68 +0,0 @@
-error: expected identifier, found keyword `async`
- --> $DIR/edition-keywords-2018-2018-parsing.rs:16:13
- |
-LL | let mut async = 1;
- | ^^^^^ expected identifier, found keyword
- |
-help: escape `async` to use it as an identifier
- |
-LL | let mut r#async = 1;
- | ++
-
-error: expected identifier, found keyword `async`
- --> $DIR/edition-keywords-2018-2018-parsing.rs:26:13
- |
-LL | module::async();
- | ^^^^^ expected identifier, found keyword
- |
-help: escape `async` to use it as an identifier
- |
-LL | module::r#async();
- | ++
-
-error: no rules expected the token `r#async`
- --> $DIR/edition-keywords-2018-2018-parsing.rs:20:31
- |
-LL | r#async = consumes_async!(r#async);
- | ^^^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `async`
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:17:6
- |
-LL | (async) => (1)
- | ^^^^^
-
-error: no rules expected the token `async`
- --> $DIR/edition-keywords-2018-2018-parsing.rs:21:35
- |
-LL | r#async = consumes_async_raw!(async);
- | ^^^^^ no rules expected this token in macro call
- |
-note: while trying to match `r#async`
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:22:6
- |
-LL | (r#async) => (1)
- | ^^^^^^^
-
-error: macro expansion ends with an incomplete expression: expected one of `move`, `|`, or `||`
- --> $DIR/auxiliary/edition-kw-macro-2018.rs:27:23
- |
-LL | ($i: ident) => ($i)
- | ^ expected one of `move`, `|`, or `||`
- |
- ::: $DIR/edition-keywords-2018-2018-parsing.rs:24:8
- |
-LL | if passes_ident!(async) == 1 {}
- | -------------------- in this macro invocation
-
-error[E0308]: mismatched types
- --> $DIR/edition-keywords-2018-2018-parsing.rs:29:33
- |
-LL | let _recovery_witness: () = 0;
- | -- ^ expected `()`, found integer
- | |
- | expected due to this
-
-error: aborting due to 6 previous errors
-
-For more information about this error, try `rustc --explain E0308`.
diff --git a/src/test/ui/editions/edition-keywords-2018-2018.rs b/src/test/ui/editions/edition-keywords-2018-2018.rs
deleted file mode 100644
index 5043440aa..000000000
--- a/src/test/ui/editions/edition-keywords-2018-2018.rs
+++ /dev/null
@@ -1,34 +0,0 @@
-// run-pass
-
-#![allow(unused_assignments)]
-// edition:2018
-// aux-build:edition-kw-macro-2018.rs
-
-#[macro_use]
-extern crate edition_kw_macro_2018;
-
-pub fn check_async() {
- // let mut async = 1; // ERROR, reserved
- let mut r#async = 1; // OK
-
- r#async = consumes_async!(async); // OK
- // r#async = consumes_async!(r#async); // ERROR, not a match
- // r#async = consumes_async_raw!(async); // ERROR, not a match
- r#async = consumes_async_raw!(r#async); // OK
-
- // if passes_ident!(async) == 1 {} // ERROR, reserved
- if passes_ident!(r#async) == 1 {} // OK
- // one_async::async(); // ERROR, reserved
- // one_async::r#async(); // ERROR, unresolved name
- // two_async::async(); // ERROR, reserved
- two_async::r#async(); // OK
-}
-
-mod one_async {
- // produces_async! {} // ERROR, reserved
-}
-mod two_async {
- produces_async_raw! {} // OK
-}
-
-fn main() {}
diff --git a/src/test/ui/editions/edition-raw-pointer-method-2015.rs b/src/test/ui/editions/edition-raw-pointer-method-2015.rs
deleted file mode 100644
index fcfe493c1..000000000
--- a/src/test/ui/editions/edition-raw-pointer-method-2015.rs
+++ /dev/null
@@ -1,12 +0,0 @@
-// edition:2015
-
-// tests that editions work with the tyvar warning-turned-error
-
-#[deny(warnings)]
-fn main() {
- let x = 0;
- let y = &x as *const _;
- let _ = y.is_null();
- //~^ error: type annotations needed [tyvar_behind_raw_pointer]
- //~^^ warning: this is accepted in the current edition
-}
diff --git a/src/test/ui/editions/edition-raw-pointer-method-2015.stderr b/src/test/ui/editions/edition-raw-pointer-method-2015.stderr
deleted file mode 100644
index 612dd17e7..000000000
--- a/src/test/ui/editions/edition-raw-pointer-method-2015.stderr
+++ /dev/null
@@ -1,17 +0,0 @@
-error: type annotations needed
- --> $DIR/edition-raw-pointer-method-2015.rs:9:15
- |
-LL | let _ = y.is_null();
- | ^^^^^^^
- |
- = warning: this is accepted in the current edition (Rust 2015) but is a hard error in Rust 2018!
- = note: for more information, see issue #46906 <https://github.com/rust-lang/rust/issues/46906>
-note: the lint level is defined here
- --> $DIR/edition-raw-pointer-method-2015.rs:5:8
- |
-LL | #[deny(warnings)]
- | ^^^^^^^^
- = note: `#[deny(tyvar_behind_raw_pointer)]` implied by `#[deny(warnings)]`
-
-error: aborting due to previous error
-
diff --git a/src/test/ui/editions/edition-raw-pointer-method-2018.rs b/src/test/ui/editions/edition-raw-pointer-method-2018.rs
deleted file mode 100644
index af0b2d6bd..000000000
--- a/src/test/ui/editions/edition-raw-pointer-method-2018.rs
+++ /dev/null
@@ -1,11 +0,0 @@
-// edition:2018
-
-// tests that editions work with the tyvar warning-turned-error
-
-#[deny(warnings)]
-fn main() {
- let x = 0;
- let y = &x as *const _;
- let _ = y.is_null();
- //~^ error: the type of this value must be known to call a method on a raw pointer on it [E0699]
-}
diff --git a/src/test/ui/editions/edition-raw-pointer-method-2018.stderr b/src/test/ui/editions/edition-raw-pointer-method-2018.stderr
deleted file mode 100644
index 23452495b..000000000
--- a/src/test/ui/editions/edition-raw-pointer-method-2018.stderr
+++ /dev/null
@@ -1,9 +0,0 @@
-error[E0699]: the type of this value must be known to call a method on a raw pointer on it
- --> $DIR/edition-raw-pointer-method-2018.rs:9:15
- |
-LL | let _ = y.is_null();
- | ^^^^^^^
-
-error: aborting due to previous error
-
-For more information about this error, try `rustc --explain E0699`.
diff --git a/src/test/ui/editions/epoch-gate-feature.rs b/src/test/ui/editions/epoch-gate-feature.rs
deleted file mode 100644
index 5f7feb534..000000000
--- a/src/test/ui/editions/epoch-gate-feature.rs
+++ /dev/null
@@ -1,15 +0,0 @@
-// run-pass
-
-#![allow(dead_code)]
-#![allow(unused_variables)]
-// Checks if the correct registers are being used to pass arguments
-// when the sysv64 ABI is specified.
-
-#![feature(rust_2018_preview)]
-
-pub trait Foo {}
-
-// should compile without the dyn trait feature flag
-fn foo(x: &dyn Foo) {}
-
-pub fn main() {}