Fix stable feature names in tests

This commit is contained in:
David Tolnay 2023-10-15 12:53:37 -07:00
parent 67ea7986c7
commit 01b909174b
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82
4 changed files with 11 additions and 11 deletions

View File

@ -1,8 +1,8 @@
// This file provides a const function that is unstably const forever.
#![feature(staged_api)]
#![stable(feature = "1", since = "1.0.0")]
#![stable(feature = "clippytest", since = "1.0.0")]
#[stable(feature = "1", since = "1.0.0")]
#[stable(feature = "clippytest", since = "1.0.0")]
#[rustc_const_unstable(feature = "foo", issue = "none")]
pub const fn unstably_const_fn() {}

View File

@ -1,12 +1,12 @@
#![feature(staged_api)]
#![stable(feature = "deprecated-future-staged-api", since = "1.0.0")]
#![stable(feature = "deprecated_future_staged_api", since = "1.0.0")]
// @has deprecated_future_staged_api/index.html '//*[@class="stab deprecated"]' \
// 'Deprecation planned'
// @has deprecated_future_staged_api/struct.S1.html '//*[@class="stab deprecated"]' \
// 'Deprecating in 99.99.99: effectively never'
#[deprecated(since = "99.99.99", note = "effectively never")]
#[stable(feature = "deprecated-future-staged-api", since = "1.0.0")]
#[stable(feature = "deprecated_future_staged_api", since = "1.0.0")]
pub struct S1;
// @has deprecated_future_staged_api/index.html '//*[@class="stab deprecated"]' \
@ -14,5 +14,5 @@ pub struct S1;
// @has deprecated_future_staged_api/struct.S2.html '//*[@class="stab deprecated"]' \
// 'Deprecating in a future Rust version: literally never'
#[deprecated(since = "TBD", note = "literally never")]
#[stable(feature = "deprecated-future-staged-api", since = "1.0.0")]
#[stable(feature = "deprecated_future_staged_api", since = "1.0.0")]
pub struct S2;

View File

@ -2,14 +2,14 @@
#![feature(staged_api)]
#![stable(feature = "rustc_deprecation-in-future-test", since = "1.0.0")]
#![stable(feature = "rustc_deprecation_in_future_test", since = "1.0.0")]
#[deprecated(since = "99.99.99", note = "effectively never")]
#[stable(feature = "rustc_deprecation-in-future-test", since = "1.0.0")]
#[stable(feature = "rustc_deprecation_in_future_test", since = "1.0.0")]
pub struct S1;
#[deprecated(since = "TBD", note = "literally never")]
#[stable(feature = "rustc_deprecation-in-future-test", since = "1.0.0")]
#[stable(feature = "rustc_deprecation_in_future_test", since = "1.0.0")]
pub struct S2;
fn main() {

View File

@ -8,7 +8,7 @@
#![feature(no_core, lang_items, intrinsics, staged_api, rustc_attrs)]
#![no_core]
#![crate_type = "lib"]
#![stable(feature = "", since = "")]
#![stable(feature = "intrinsics_for_test", since = "")]
#![allow(dead_code)]
// Test that the repr(C) attribute doesn't break compilation
@ -22,8 +22,8 @@ enum Foo {
}
extern "rust-intrinsic" {
#[stable(feature = "", since = "")]
#[rustc_const_stable(feature = "", since = "")]
#[stable(feature = "intrinsics_for_test", since = "")]
#[rustc_const_stable(feature = "intrinsics_for_test", since = "")]
#[rustc_safe_intrinsic]
fn size_of<T>() -> usize;
}