Rename ACTIVE_FEATURES
as UNSTABLE_FEATURES
.
It's a better name, and lets "active features" refer to the features that are active in a particular program, due to being declared or enabled by the edition. The commit also renames `Features::enabled` as `Features::active` to match this; I changed my mind and have decided that "active" is a little better thatn "enabled" for this, particularly because a number of pre-existing comments use "active" in this way. Finally, the commit renames `Status::Stable` as `Status::Accepted`, to match `ACCEPTED_FEATURES`.
This commit is contained in:
parent
41b6899487
commit
d284c8a2d7
14 changed files with 199 additions and 201 deletions
|
@ -39,7 +39,7 @@ pub struct GatedSpans {
|
|||
|
||||
impl GatedSpans {
|
||||
/// Feature gate the given `span` under the given `feature`
|
||||
/// which is same `Symbol` used in `active.rs`.
|
||||
/// which is same `Symbol` used in `unstable.rs`.
|
||||
pub fn gate(&self, feature: Symbol, span: Span) {
|
||||
self.spans.borrow_mut().entry(feature).or_default().push(span);
|
||||
}
|
||||
|
@ -78,7 +78,7 @@ impl SymbolGallery {
|
|||
}
|
||||
|
||||
/// Construct a diagnostic for a language feature error due to the given `span`.
|
||||
/// The `feature`'s `Symbol` is the one you used in `active.rs` and `rustc_span::symbols`.
|
||||
/// The `feature`'s `Symbol` is the one you used in `unstable.rs` and `rustc_span::symbols`.
|
||||
#[track_caller]
|
||||
pub fn feature_err(
|
||||
sess: &ParseSess,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue