Skip to content

Commit

Permalink
Fix stable feature names in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Oct 16, 2023
1 parent 73d645e commit 303475f
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
@@ -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() {}
6 changes: 3 additions & 3 deletions tests/rustdoc/deprecated-future-staged-api.rs
@@ -1,18 +1,18 @@
#![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"]' \
// 'Deprecation planned'
// @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;
6 changes: 3 additions & 3 deletions tests/ui/deprecation/staged-deprecation-in-future.rs
Expand Up @@ -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() {
Expand Down
6 changes: 3 additions & 3 deletions tests/ui/repr/16-bit-repr-c-enum.rs
Expand Up @@ -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
Expand All @@ -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;
}
Expand Down

0 comments on commit 303475f

Please sign in to comment.