remove no longer needd UnstableFeature type
This commit is contained in:
parent
6ad17bd30c
commit
e82bca6f32
4 changed files with 9 additions and 15 deletions
|
@ -94,8 +94,8 @@ impl UnstableFeatures {
|
|||
|
||||
fn find_lang_feature_issue(feature: Symbol) -> Option<NonZero<u32>> {
|
||||
// Search in all the feature lists.
|
||||
if let Some(f) = UNSTABLE_FEATURES.iter().find(|f| f.feature.name == feature) {
|
||||
return f.feature.issue;
|
||||
if let Some(f) = UNSTABLE_FEATURES.iter().find(|f| f.name == feature) {
|
||||
return f.issue;
|
||||
}
|
||||
if let Some(f) = ACCEPTED_FEATURES.iter().find(|f| f.name == feature) {
|
||||
return f.issue;
|
||||
|
|
|
@ -6,10 +6,6 @@ use rustc_span::symbol::{Symbol, sym};
|
|||
|
||||
use super::{Feature, to_nonzero};
|
||||
|
||||
pub struct UnstableFeature {
|
||||
pub feature: Feature,
|
||||
}
|
||||
|
||||
#[derive(PartialEq)]
|
||||
enum FeatureStatus {
|
||||
Default,
|
||||
|
@ -82,13 +78,11 @@ macro_rules! declare_features {
|
|||
)+) => {
|
||||
/// Unstable language features that are being implemented or being
|
||||
/// considered for acceptance (stabilization) or removal.
|
||||
pub const UNSTABLE_FEATURES: &[UnstableFeature] = &[
|
||||
$(UnstableFeature {
|
||||
feature: Feature {
|
||||
name: sym::$feature,
|
||||
since: $ver,
|
||||
issue: to_nonzero($issue),
|
||||
},
|
||||
pub const UNSTABLE_FEATURES: &[Feature] = &[
|
||||
$(Feature {
|
||||
name: sym::$feature,
|
||||
since: $ver,
|
||||
issue: to_nonzero($issue),
|
||||
}),+
|
||||
];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue