Skip to content

Commit

Permalink
Bless tests
Browse files Browse the repository at this point in the history
Update tests
  • Loading branch information
George-lewis committed Jan 13, 2024
1 parent 6e92b6e commit 0957eaa
Show file tree
Hide file tree
Showing 406 changed files with 1,363 additions and 318 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
//~^^^ WARNING custom classes in code blocks will change behaviour
//~| NOTE found these custom classes: class=language-c
//~| NOTE see issue #79483 <https://github.com/rust-lang/rust/issues/79483>
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
//~| HELP add `#![feature(custom_code_classes_in_docs)]` to the crate attributes to enable
pub struct Bar;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ LL | | /// ```
|
= note: see issue #79483 <https://github.com/rust-lang/rust/issues/79483> for more information
= help: add `#![feature(custom_code_classes_in_docs)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
= note: found these custom classes: class=language-c

warning: 1 warning emitted
Expand Down
1 change: 1 addition & 0 deletions tests/rustdoc-ui/feature-gate-doc_cfg_hide.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | #![doc(cfg_hide(test))]
|
= note: see issue #43781 <https://github.com/rust-lang/rust/issues/43781> for more information
= help: add `#![feature(doc_cfg_hide)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 1 previous error

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | //! [pointer::add]
|
= note: see issue #80896 <https://github.com/rust-lang/rust/issues/80896> for more information
= help: add `#![feature(intra_doc_pointers)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
= note: rustdoc does not allow disambiguating between `*const` and `*mut`, and pointers are unstable until it does

error[E0658]: linking to associated items of raw pointers is experimental
Expand All @@ -16,6 +17,7 @@ LL | //! [pointer::wrapping_add]
|
= note: see issue #80896 <https://github.com/rust-lang/rust/issues/80896> for more information
= help: add `#![feature(intra_doc_pointers)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
= note: rustdoc does not allow disambiguating between `*const` and `*mut`, and pointers are unstable until it does

error: aborting due to 2 previous errors
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
//~^ ERROR unknown lint
//~| NOTE lint is unstable
//~| NOTE see issue
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ LL | #![allow(rustdoc::missing_doc_code_examples)]
= note: the `rustdoc::missing_doc_code_examples` lint is unstable
= note: see issue #101730 <https://github.com/rust-lang/rust/issues/101730> for more information
= help: add `#![feature(rustdoc_missing_doc_code_examples)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
note: the lint level is defined here
--> $DIR/feature-gate-rustdoc_missing_doc_code_examples.rs:2:9
|
Expand Down
15 changes: 15 additions & 0 deletions tests/ui-fulldeps/hash-stable-is-unstable.rs
Original file line number Diff line number Diff line change
@@ -1,16 +1,31 @@
// ignore-stage1
// compile-flags: -Zdeduplicate-diagnostics=yes
extern crate rustc_data_structures;
//~^ use of unstable library feature 'rustc_private'
//~| NOTE: issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
extern crate rustc_macros;
//~^ use of unstable library feature 'rustc_private'
//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
extern crate rustc_query_system;
//~^ use of unstable library feature 'rustc_private'
//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

use rustc_macros::HashStable;
//~^ use of unstable library feature 'rustc_private'
//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

#[derive(HashStable)]
//~^ use of unstable library feature 'rustc_private'
//~| NOTE: in this expansion of #[derive(HashStable)]
//~| NOTE: in this expansion of #[derive(HashStable)]
//~| NOTE: in this expansion of #[derive(HashStable)]
//~| NOTE: in this expansion of #[derive(HashStable)]
//~| NOTE: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
//~| NOTE: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
struct Test;

fn main() {}
15 changes: 10 additions & 5 deletions tests/ui-fulldeps/hash-stable-is-unstable.stderr
Original file line number Diff line number Diff line change
@@ -1,47 +1,52 @@
error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
--> $DIR/hash-stable-is-unstable.rs:2:1
--> $DIR/hash-stable-is-unstable.rs:3:1
|
LL | extern crate rustc_data_structures;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
= help: add `#![feature(rustc_private)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
--> $DIR/hash-stable-is-unstable.rs:4:1
--> $DIR/hash-stable-is-unstable.rs:7:1
|
LL | extern crate rustc_macros;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
= help: add `#![feature(rustc_private)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
--> $DIR/hash-stable-is-unstable.rs:6:1
--> $DIR/hash-stable-is-unstable.rs:11:1
|
LL | extern crate rustc_query_system;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
= help: add `#![feature(rustc_private)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
--> $DIR/hash-stable-is-unstable.rs:9:5
--> $DIR/hash-stable-is-unstable.rs:16:5
|
LL | use rustc_macros::HashStable;
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
= help: add `#![feature(rustc_private)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
--> $DIR/hash-stable-is-unstable.rs:12:10
--> $DIR/hash-stable-is-unstable.rs:21:10
|
LL | #[derive(HashStable)]
| ^^^^^^^^^^
|
= note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
= help: add `#![feature(rustc_private)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
= note: this error originates in the derive macro `HashStable` (in Nightly builds, run with -Z macro-backtrace for more info)

error: aborting due to 5 previous errors
Expand Down
1 change: 1 addition & 0 deletions tests/ui-fulldeps/pathless-extern-unstable.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// edition:2018
// ignore-stage1
// compile-flags:--extern rustc_middle

// Test that `--extern rustc_middle` fails with `rustc_private`.
Expand Down
3 changes: 2 additions & 1 deletion tests/ui-fulldeps/pathless-extern-unstable.stderr
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
error[E0658]: use of unstable library feature 'rustc_private': this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via `Cargo.toml` instead?
--> $DIR/pathless-extern-unstable.rs:6:9
--> $DIR/pathless-extern-unstable.rs:7:9
|
LL | pub use rustc_middle;
| ^^^^^^^^^^^^
|
= note: see issue #27812 <https://github.com/rust-lang/rust/issues/27812> for more information
= help: add `#![feature(rustc_private)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 1 previous error

Expand Down
7 changes: 7 additions & 0 deletions tests/ui/array-slice-vec/suggest-array-length.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ LL | const Foo: [i32; _] = [1, 2, 3];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: using `_` for array lengths is unstable
--> $DIR/suggest-array-length.rs:8:26
Expand All @@ -57,6 +58,7 @@ LL | const REF_FOO: &[u8; _] = &[1];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: using `_` for array lengths is unstable
--> $DIR/suggest-array-length.rs:11:20
Expand All @@ -66,6 +68,7 @@ LL | let foo: [i32; _] = [1, 2, 3];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: using `_` for array lengths is unstable
--> $DIR/suggest-array-length.rs:14:20
Expand All @@ -75,6 +78,7 @@ LL | let bar: [i32; _] = [0; 3];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: using `_` for array lengths is unstable
--> $DIR/suggest-array-length.rs:17:25
Expand All @@ -84,6 +88,7 @@ LL | let ref_foo: &[i32; _] = &[1, 2, 3];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: using `_` for array lengths is unstable
--> $DIR/suggest-array-length.rs:20:25
Expand All @@ -93,6 +98,7 @@ LL | let ref_bar: &[i32; _] = &[0; 3];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: using `_` for array lengths is unstable
--> $DIR/suggest-array-length.rs:23:35
Expand All @@ -102,6 +108,7 @@ LL | let multiple_ref_foo: &&[i32; _] = &&[1, 2, 3];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 14 previous errors

Expand Down
2 changes: 2 additions & 0 deletions tests/ui/associated-consts/issue-105330.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ LL | fn foo<A: TraitWAssocConst<A=32>>() {
|
= note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
= help: add `#![feature(associated_const_equality)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: associated const equality is incomplete
--> $DIR/issue-105330.rs:15:29
Expand All @@ -32,6 +33,7 @@ LL | fn main<A: TraitWAssocConst<A=32>>() {
|
= note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
= help: add `#![feature(associated_const_equality)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0562]: `impl Trait` is not allowed in impl headers
--> $DIR/issue-105330.rs:6:27
Expand Down
2 changes: 2 additions & 0 deletions tests/ui/associated-consts/issue-93835.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ LL | type_ascribe!(p, a<p:p<e=6>>);
|
= note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
= help: add `#![feature(associated_const_equality)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: associated type bounds are unstable
--> $DIR/issue-93835.rs:4:24
Expand All @@ -33,6 +34,7 @@ LL | type_ascribe!(p, a<p:p<e=6>>);
|
= note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
= help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 5 previous errors

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ LL | type Data = aux::Owner::Data;
| ^^^^^^^^^^^^^^^^
|
= help: add `#![feature(data)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 1 previous error

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ LL | impl S { type P = (); }
|
= note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
= help: add `#![feature(inherent_associated_types)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 2 previous errors

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ LL | type Item = &[T];
|
= note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
= help: add `#![feature(inherent_associated_types)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0223]: ambiguous associated type
--> $DIR/issue-109071.rs:15:22
Expand Down
1 change: 1 addition & 0 deletions tests/ui/associated-inherent-types/issue-109768.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ LL | type AssocType3 = T;
|
= note: see issue #8995 <https://github.com/rust-lang/rust/issues/8995> for more information
= help: add `#![feature(inherent_associated_types)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0061]: this struct takes 1 argument but 0 arguments were supplied
--> $DIR/issue-109768.rs:10:56
Expand Down
1 change: 1 addition & 0 deletions tests/ui/associated-type-bounds/issue-99828.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | fn get_iter(vec: &[i32]) -> impl Iterator<Item = {}> + '_ {
|
= note: see issue #92827 <https://github.com/rust-lang/rust/issues/92827> for more information
= help: add `#![feature(associated_const_equality)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: expected type, found constant
--> $DIR/issue-99828.rs:1:50
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LL | fn foo<T: Trait<method(i32): Send>>() {}
|
= note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
= help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: associated type bounds are unstable
--> $DIR/bad-inputs-and-output.rs:14:17
Expand All @@ -21,6 +22,7 @@ LL | fn bar<T: Trait<method() -> (): Send>>() {}
|
= note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
= help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

warning: the feature `return_type_notation` is incomplete and may not be safe to use and/or cause compiler crashes
--> $DIR/bad-inputs-and-output.rs:3:12
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | fn foo<T: Trait<method(i32): Send>>() {}
|
= note: see issue #52662 <https://github.com/rust-lang/rust/issues/52662> for more information
= help: add `#![feature(associated_type_bounds)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 1 previous error

Expand Down
1 change: 1 addition & 0 deletions tests/ui/async-await/feature-async-closure.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | let _ = async || {};
|
= note: see issue #62290 <https://github.com/rust-lang/rust/issues/62290> for more information
= help: add `#![feature(async_closure)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date
= help: to use an async block, remove the `||`: `async {`

error: aborting due to 1 previous error
Expand Down
2 changes: 2 additions & 0 deletions tests/ui/async-await/feature-async-for-loop.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | for await _i in core::async_iter::from_iter(0..3) {
|
= note: see issue #118898 <https://github.com/rust-lang/rust/issues/118898> for more information
= help: add `#![feature(async_for_loop)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: `for await` loops are experimental
--> $DIR/feature-async-for-loop.rs:17:13
Expand All @@ -15,6 +16,7 @@ LL | for await _i in core::async_iter::from_iter(0..3) {
|
= note: see issue #118898 <https://github.com/rust-lang/rust/issues/118898> for more information
= help: add `#![feature(async_for_loop)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 2 previous errors

Expand Down
1 change: 1 addition & 0 deletions tests/ui/async-await/issues/issue-95307.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ LL | async fn new() -> [u8; _];
|
= note: see issue #85077 <https://github.com/rust-lang/rust/issues/85077> for more information
= help: add `#![feature(generic_arg_infer)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 2 previous errors

Expand Down
3 changes: 3 additions & 0 deletions tests/ui/async-await/track-caller/async-block.afn.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ LL | let _ = #[track_caller] async {
|
= note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
= help: add `#![feature(closure_track_caller)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: `#[track_caller]` on closures is currently unstable
--> $DIR/async-block.rs:15:13
Expand All @@ -15,6 +16,7 @@ LL | let _ = #[track_caller] async {
|
= note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
= help: add `#![feature(closure_track_caller)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error[E0658]: `#[track_caller]` on closures is currently unstable
--> $DIR/async-block.rs:23:17
Expand All @@ -24,6 +26,7 @@ LL | let _ = #[track_caller] async {
|
= note: see issue #87417 <https://github.com/rust-lang/rust/issues/87417> for more information
= help: add `#![feature(closure_track_caller)]` to the crate attributes to enable
= note: this compiler was built on YYYY-MM-DD; consider upgrading it if it is out of date

error: aborting due to 3 previous errors

Expand Down
Loading

0 comments on commit 0957eaa

Please sign in to comment.