Allow the unstable attribute on foreign type#158233
Conversation
|
Some changes occurred in compiler/rustc_attr_parsing |
|
Thanks for the pull request, and welcome! The Rust Project is excited to review your changes, and you should hear from @JonathanBrouwer (or someone else) some time within the next two weeks. Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (
|
This comment has been minimized.
This comment has been minimized.
| #![stable(feature = "rust1", since = "1.0.0")] | ||
|
|
||
| extern "C" { | ||
| #[unstable(feature = "fn_static", issue = "none")] |
There was a problem hiding this comment.
This test doesn't actually test that the attribute has an effect, only that it is allowed. Maybe add this to the ui/lint/lint-stability tests instead?
There was a problem hiding this comment.
I'd specifically like to see an error being produced for the use of the unstable foreign type
|
Reminder, once the PR becomes ready for a review, use |
b915a1c to
4b98d4c
Compare
8fd861c to
b973eb9
Compare
|
The job Click to see the possible cause of the failure (guessed by this bot) |
While working the
FnPtrtrait in #156176 @carbotaniuman was trying to implementCodeas an extern type but got an error as the current stability infrastructure does not allowunstableattribute on foreign type. #158200This PR fixes that by allowing the
unstableattribute on ForeignTy and adds test to verify.@rustbot r? @JonathanBrouwer