Skip to content

Commit 5950df6

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 7d60f8d commit 5950df6

File tree

46 files changed

+838
-387
lines changed

Some content is hidden

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

46 files changed

+838
-387
lines changed

Cargo.lock

+3
Original file line numberDiff line numberDiff line change
@@ -3333,6 +3333,7 @@ dependencies = [
33333333
"rustc_serialize",
33343334
"rustc_session",
33353335
"rustc_span",
3336+
"smallvec",
33363337
]
33373338

33383339
[[package]]
@@ -3505,6 +3506,7 @@ dependencies = [
35053506
"rustc_target",
35063507
"rustc_trait_selection",
35073508
"rustc_type_ir",
3509+
"smallvec",
35083510
"tracing",
35093511
]
35103512

@@ -4217,6 +4219,7 @@ dependencies = [
42174219
"rustc_span",
42184220
"rustc_target",
42194221
"rustc_trait_selection",
4222+
"smallvec",
42204223
"tracing",
42214224
]
42224225

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)