Rollup merge of #94213 - digama0:patch-4, r=Dylan-DPC

fix names in feature(...) suggestion
This commit is contained in:
Matthias Krüger 2022-02-23 12:26:41 +01:00 committed by GitHub
commit 14ac74d438
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View file

@ -453,7 +453,7 @@ pub const BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
// Internal attributes: Stability, deprecation, and unsafe:
// ==========================================================================
ungated!(feature, CrateLevel, template!(List: "name1, name1, ..."), DuplicatesOk),
ungated!(feature, CrateLevel, template!(List: "name1, name2, ..."), DuplicatesOk),
// DuplicatesOk since it has its own validation
ungated!(
rustc_deprecated, Normal,

View file

@ -20,13 +20,13 @@ error: malformed `feature` attribute input
--> $DIR/gated-bad-feature.rs:5:1
|
LL | #![feature]
| ^^^^^^^^^^^ help: must be of the form: `#![feature(name1, name1, ...)]`
| ^^^^^^^^^^^ help: must be of the form: `#![feature(name1, name2, ...)]`
error: malformed `feature` attribute input
--> $DIR/gated-bad-feature.rs:6:1
|
LL | #![feature = "foo"]
| ^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#![feature(name1, name1, ...)]`
| ^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#![feature(name1, name2, ...)]`
error: aborting due to 5 previous errors