feature gate doc(primitive)
This commit is contained in:
parent
2bd17c1d43
commit
03df65497e
9 changed files with 49 additions and 7 deletions
|
|
@ -2,6 +2,7 @@
|
|||
// check-pass
|
||||
|
||||
#![feature(doc_keyword)]
|
||||
#![feature(doc_primitive)]
|
||||
|
||||
//! the features only used in std also have entries in the table, so make sure those get pulled out
|
||||
//! properly as well
|
||||
|
|
|
|||
8
src/test/ui/rustdoc/feature-gate-doc_primitive.rs
Normal file
8
src/test/ui/rustdoc/feature-gate-doc_primitive.rs
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
// check-pass
|
||||
#[doc(primitive = "usize")]
|
||||
//~^ WARNING `doc(primitive)` should never have been stable
|
||||
//~| WARNING hard error in a future release
|
||||
/// Some docs
|
||||
mod usize {}
|
||||
|
||||
fn main() {}
|
||||
12
src/test/ui/rustdoc/feature-gate-doc_primitive.stderr
Normal file
12
src/test/ui/rustdoc/feature-gate-doc_primitive.stderr
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
warning: `doc(primitive)` should never have been stable
|
||||
--> $DIR/feature-gate-doc_primitive.rs:2:7
|
||||
|
|
||||
LL | #[doc(primitive = "usize")]
|
||||
| ^^^^^^^^^^^^^^^^^^^
|
||||
|
|
||||
= note: `#[warn(invalid_doc_attributes)]` on by default
|
||||
= 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>
|
||||
|
||||
warning: 1 warning emitted
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue