Struct rustc_session::parse::GatedSpans [−][src]
Expand description
Collected spans during parsing for places where a certain feature was
used and should be feature gated accordingly in check_crate.
Fields
spans: Lock<FxHashMap<Symbol, Vec<Span>>>Implementations
impl GatedSpans[src]
impl GatedSpans[src]pub fn gate(&self, feature: Symbol, span: Span)[src]
pub fn gate(&self, feature: Symbol, span: Span)[src]Feature gate the given span under the given feature
which is same Symbol used in active.rs.
pub fn ungate_last(&self, feature: Symbol, span: Span)[src]
pub fn ungate_last(&self, feature: Symbol, span: Span)[src]Ungate the last span under the given feature.
Panics if the given span wasn’t the last one.
Using this is discouraged unless you have a really good reason to.
pub fn is_ungated(&self, feature: Symbol) -> bool[src]
pub fn is_ungated(&self, feature: Symbol) -> bool[src]Is the provided feature gate ungated currently?
Using this is discouraged unless you have a really good reason to.
Trait Implementations
impl Default for GatedSpans[src]
impl Default for GatedSpans[src]fn default() -> GatedSpans[src]
fn default() -> GatedSpans[src]Returns the “default value” for a type. Read more