diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2021-06-05 19:41:40 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-06-05 19:41:40 +0200 |
| commit | 515c5afe2ca26ff73710251eadc503b29f291b07 (patch) | |
| tree | 038e270f2c7022a9ffa24fba9a81f914d5cd68db /src/test/rustdoc-ui | |
| parent | 15940767481e82594b7d1c8fb4805521e681f854 (diff) | |
| parent | 261f64358c216941e6543e43f9ea33efa7a35ab3 (diff) | |
Rollup merge of #85501 - jyn514:invalid-doc-attrs, r=varkor
Fix `deny(invalid_doc_attributes)` Fixes https://github.com/rust-lang/rust/issues/85497.
Diffstat (limited to 'src/test/rustdoc-ui')
| -rw-r--r-- | src/test/rustdoc-ui/doc-spotlight.fixed | 5 | ||||
| -rw-r--r-- | src/test/rustdoc-ui/doc-spotlight.rs | 5 | ||||
| -rw-r--r-- | src/test/rustdoc-ui/doc-spotlight.stderr | 13 |
3 files changed, 13 insertions, 10 deletions
diff --git a/src/test/rustdoc-ui/doc-spotlight.fixed b/src/test/rustdoc-ui/doc-spotlight.fixed index 94b69a99879..4b58778eacd 100644 --- a/src/test/rustdoc-ui/doc-spotlight.fixed +++ b/src/test/rustdoc-ui/doc-spotlight.fixed @@ -1,9 +1,8 @@ -// check-pass // run-rustfix - +#![deny(warnings)] #![feature(doc_notable_trait)] #[doc(notable_trait)] -//~^ WARN unknown `doc` attribute `spotlight` +//~^ ERROR unknown `doc` attribute `spotlight` //~| WARN this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! trait MyTrait {} diff --git a/src/test/rustdoc-ui/doc-spotlight.rs b/src/test/rustdoc-ui/doc-spotlight.rs index cc5f159a809..16e38724580 100644 --- a/src/test/rustdoc-ui/doc-spotlight.rs +++ b/src/test/rustdoc-ui/doc-spotlight.rs @@ -1,9 +1,8 @@ -// check-pass // run-rustfix - +#![deny(warnings)] #![feature(doc_notable_trait)] #[doc(spotlight)] -//~^ WARN unknown `doc` attribute `spotlight` +//~^ ERROR unknown `doc` attribute `spotlight` //~| WARN this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! trait MyTrait {} diff --git a/src/test/rustdoc-ui/doc-spotlight.stderr b/src/test/rustdoc-ui/doc-spotlight.stderr index e5fa6293f3d..8e7831139a8 100644 --- a/src/test/rustdoc-ui/doc-spotlight.stderr +++ b/src/test/rustdoc-ui/doc-spotlight.stderr @@ -1,14 +1,19 @@ -warning: unknown `doc` attribute `spotlight` - --> $DIR/doc-spotlight.rs:6:7 +error: unknown `doc` attribute `spotlight` + --> $DIR/doc-spotlight.rs:5:7 | LL | #[doc(spotlight)] | ^^^^^^^^^ help: use `notable_trait` instead | - = note: `#[warn(invalid_doc_attributes)]` on by default +note: the lint level is defined here + --> $DIR/doc-spotlight.rs:2:9 + | +LL | #![deny(warnings)] + | ^^^^^^^^ + = note: `#[deny(invalid_doc_attributes)]` implied by `#[deny(warnings)]` = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! = note: for more information, see issue #82730 <https://github.com/rust-lang/rust/issues/82730> = note: `doc(spotlight)` was renamed to `doc(notable_trait)` = note: `doc(spotlight)` is now a no-op -warning: 1 warning emitted +error: aborting due to previous error |
