Skip to content

Commit 67f9341

Browse files
committed
compiler: support multiple stability attributes on items
This changes the text for E0544. Unfortunately, the example doesn't make much sense anymore. The way this merges stability levels together is made to work for stability-checking and rustdoc; as far as I can tell, only `rustc_passes::lib_features` needs them separate, and it extracts them itself. This includes the clarified/fixed const-unstable semantics that were previously in a different commit.
1 parent 039e6de commit 67f9341

File tree

45 files changed

+798
-376
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+798
-376
lines changed

Cargo.lock

+3
Original file line numberDiff line numberDiff line change
@@ -3334,6 +3334,7 @@ dependencies = [
33343334
"rustc_serialize",
33353335
"rustc_session",
33363336
"rustc_span",
3337+
"smallvec",
33373338
]
33383339

33393340
[[package]]
@@ -3506,6 +3507,7 @@ dependencies = [
35063507
"rustc_target",
35073508
"rustc_trait_selection",
35083509
"rustc_type_ir",
3510+
"smallvec",
35093511
"tracing",
35103512
]
35113513

@@ -4218,6 +4220,7 @@ dependencies = [
42184220
"rustc_span",
42194221
"rustc_target",
42204222
"rustc_trait_selection",
4223+
"smallvec",
42214224
"tracing",
42224225
]
42234226

compiler/rustc_attr/Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,5 @@ rustc_macros = { path = "../rustc_macros" }
1717
rustc_serialize = { path = "../rustc_serialize" }
1818
rustc_session = { path = "../rustc_session" }
1919
rustc_span = { path = "../rustc_span" }
20+
smallvec = { version = "1.8.1", features = ["union", "may_dangle"] }
2021
# tidy-alphabetical-end

compiler/rustc_attr/messages.ftl

+1-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ attr_multiple_item =
8383
multiple '{$item}' items
8484
8585
attr_multiple_stability_levels =
86-
multiple stability levels
86+
multiple stability levels for feature `{$feature}`
8787
8888
attr_non_ident_feature =
8989
'feature' is not an identifier

0 commit comments

Comments
 (0)