Add hyphen to "crate level"
"crate level attribute" -> "crate-level attribute"
This commit is contained in:
parent
fe64970ed1
commit
5134047c40
6 changed files with 9 additions and 9 deletions
|
@ -520,7 +520,7 @@ impl CheckAttrVisitor<'tcx> {
|
||||||
.struct_span_err(
|
.struct_span_err(
|
||||||
meta.span(),
|
meta.span(),
|
||||||
&format!(
|
&format!(
|
||||||
"`#![doc({} = \"...\")]` isn't allowed as a crate level attribute",
|
"`#![doc({} = \"...\")]` isn't allowed as a crate-level attribute",
|
||||||
attr_name,
|
attr_name,
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
@ -559,7 +559,7 @@ impl CheckAttrVisitor<'tcx> {
|
||||||
|lint| {
|
|lint| {
|
||||||
lint.build(
|
lint.build(
|
||||||
"`#![doc(test(...)]` is only allowed \
|
"`#![doc(test(...)]` is only allowed \
|
||||||
as a crate level attribute",
|
as a crate-level attribute",
|
||||||
)
|
)
|
||||||
.emit();
|
.emit();
|
||||||
},
|
},
|
||||||
|
|
|
@ -4,7 +4,7 @@ error: '\'' character isn't allowed in `#[doc(alias = "...")]`
|
||||||
LL | #[doc(alias = "shouldn't work!")]
|
LL | #[doc(alias = "shouldn't work!")]
|
||||||
| ^^^^^^^^^^^^^^^^^
|
| ^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
error: `#![doc(alias = "...")]` isn't allowed as a crate level attribute
|
error: `#![doc(alias = "...")]` isn't allowed as a crate-level attribute
|
||||||
--> $DIR/doc-alias-crate-level.rs:1:8
|
--> $DIR/doc-alias-crate-level.rs:1:8
|
||||||
|
|
|
|
||||||
LL | #![doc(alias = "crate-level-not-working")]
|
LL | #![doc(alias = "crate-level-not-working")]
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
error: `#![doc(test(...)]` is only allowed as a crate level attribute
|
error: `#![doc(test(...)]` is only allowed as a crate-level attribute
|
||||||
--> $DIR/doc-attr2.rs:4:7
|
--> $DIR/doc-attr2.rs:4:7
|
||||||
|
|
|
|
||||||
LL | #[doc(test(no_crate_inject))]
|
LL | #[doc(test(no_crate_inject))]
|
||||||
|
@ -13,7 +13,7 @@ LL | #![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!
|
= 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: for more information, see issue #82730 <https://github.com/rust-lang/rust/issues/82730>
|
||||||
|
|
||||||
error: `#![doc(test(...)]` is only allowed as a crate level attribute
|
error: `#![doc(test(...)]` is only allowed as a crate-level attribute
|
||||||
--> $DIR/doc-attr2.rs:9:12
|
--> $DIR/doc-attr2.rs:9:12
|
||||||
|
|
|
|
||||||
LL | #![doc(test(no_crate_inject))]
|
LL | #![doc(test(no_crate_inject))]
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
error: `#![doc(test(...)]` is only allowed as a crate level attribute
|
error: `#![doc(test(...)]` is only allowed as a crate-level attribute
|
||||||
--> $DIR/doc-attr2.rs:4:7
|
--> $DIR/doc-attr2.rs:4:7
|
||||||
|
|
|
|
||||||
LL | #[doc(test(no_crate_inject))]
|
LL | #[doc(test(no_crate_inject))]
|
||||||
|
@ -13,7 +13,7 @@ LL | #![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!
|
= 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: for more information, see issue #82730 <https://github.com/rust-lang/rust/issues/82730>
|
||||||
|
|
||||||
error: `#![doc(test(...)]` is only allowed as a crate level attribute
|
error: `#![doc(test(...)]` is only allowed as a crate-level attribute
|
||||||
--> $DIR/doc-attr2.rs:9:12
|
--> $DIR/doc-attr2.rs:9:12
|
||||||
|
|
|
|
||||||
LL | #![doc(test(no_crate_inject))]
|
LL | #![doc(test(no_crate_inject))]
|
||||||
|
|
|
@ -4,7 +4,7 @@ error: '\'' character isn't allowed in `#[doc(alias = "...")]`
|
||||||
LL | #[doc(alias = "shouldn't work!")]
|
LL | #[doc(alias = "shouldn't work!")]
|
||||||
| ^^^^^^^^^^^^^^^^^
|
| ^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
error: `#![doc(alias = "...")]` isn't allowed as a crate level attribute
|
error: `#![doc(alias = "...")]` isn't allowed as a crate-level attribute
|
||||||
--> $DIR/doc-alias-crate-level.rs:5:8
|
--> $DIR/doc-alias-crate-level.rs:5:8
|
||||||
|
|
|
|
||||||
LL | #![doc(alias = "not working!")]
|
LL | #![doc(alias = "not working!")]
|
||||||
|
|
|
@ -10,7 +10,7 @@ error: `#[doc(keyword = "...")]` can only be used on modules
|
||||||
LL | #[doc(keyword = "hall")]
|
LL | #[doc(keyword = "hall")]
|
||||||
| ^^^^^^^^^^^^^^^^
|
| ^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
error: `#![doc(keyword = "...")]` isn't allowed as a crate level attribute
|
error: `#![doc(keyword = "...")]` isn't allowed as a crate-level attribute
|
||||||
--> $DIR/doc_keyword.rs:4:8
|
--> $DIR/doc_keyword.rs:4:8
|
||||||
|
|
|
|
||||||
LL | #![doc(keyword = "hello")]
|
LL | #![doc(keyword = "hello")]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue