Skip to content

Commit dfce191

Browse files
committed
Fix typo in deprecation lint message
1 parent 8e978cb commit dfce191

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

compiler/rustc_expand/src/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -337,15 +337,15 @@ impl<'a> StripUnconfigured<'a> {
337337
rustc_lint_defs::builtin::DEPRECATED_CFG_ATTR_CRATE_TYPE_NAME,
338338
attr.span,
339339
ast::CRATE_NODE_ID,
340-
"`crate_type` within an `#![cfg_attr] attribute is deprecated`",
340+
"`crate_type` within an `#![cfg_attr]` attribute is deprecated",
341341
);
342342
}
343343
if attr.has_name(sym::crate_name) {
344344
self.sess.psess.buffer_lint(
345345
rustc_lint_defs::builtin::DEPRECATED_CFG_ATTR_CRATE_TYPE_NAME,
346346
attr.span,
347347
ast::CRATE_NODE_ID,
348-
"`crate_name` within an `#![cfg_attr] attribute is deprecated`",
348+
"`crate_name` within an `#![cfg_attr]` attribute is deprecated",
349349
);
350350
}
351351
attr

tests/ui/cfg/future-compat-crate-attributes-using-cfg_attr.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
error: `crate_type` within an `#![cfg_attr] attribute is deprecated`
1+
error: `crate_type` within an `#![cfg_attr]` attribute is deprecated
22
--> $DIR/future-compat-crate-attributes-using-cfg_attr.rs:4:18
33
|
44
LL | #![cfg_attr(foo, crate_type="bin")]
@@ -8,7 +8,7 @@ LL | #![cfg_attr(foo, crate_type="bin")]
88
= note: for more information, see issue #91632 <https://github.com/rust-lang/rust/issues/91632>
99
= note: `#[deny(deprecated_cfg_attr_crate_type_name)]` on by default
1010

11-
error: `crate_name` within an `#![cfg_attr] attribute is deprecated`
11+
error: `crate_name` within an `#![cfg_attr]` attribute is deprecated
1212
--> $DIR/future-compat-crate-attributes-using-cfg_attr.rs:9:18
1313
|
1414
LL | #![cfg_attr(foo, crate_name="bar")]
@@ -17,7 +17,7 @@ LL | #![cfg_attr(foo, crate_name="bar")]
1717
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
1818
= note: for more information, see issue #91632 <https://github.com/rust-lang/rust/issues/91632>
1919

20-
error: `crate_type` within an `#![cfg_attr] attribute is deprecated`
20+
error: `crate_type` within an `#![cfg_attr]` attribute is deprecated
2121
--> $DIR/future-compat-crate-attributes-using-cfg_attr.rs:4:18
2222
|
2323
LL | #![cfg_attr(foo, crate_type="bin")]
@@ -27,7 +27,7 @@ LL | #![cfg_attr(foo, crate_type="bin")]
2727
= note: for more information, see issue #91632 <https://github.com/rust-lang/rust/issues/91632>
2828
= note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
2929

30-
error: `crate_name` within an `#![cfg_attr] attribute is deprecated`
30+
error: `crate_name` within an `#![cfg_attr]` attribute is deprecated
3131
--> $DIR/future-compat-crate-attributes-using-cfg_attr.rs:9:18
3232
|
3333
LL | #![cfg_attr(foo, crate_name="bar")]

0 commit comments

Comments
 (0)