[−][src]Struct syntax::parse::ParseSess
Info about a parsing session.
Fields
span_diagnostic: Handler
unstable_features: UnstableFeatures
config: CrateConfig
missing_fragment_specifiers: Lock<FxHashSet<Span>>
raw_identifier_spans: Lock<Vec<Span>>
Places where raw identifiers were used. This is used for feature-gating raw identifiers.
buffered_lints: Lock<Vec<BufferedEarlyLint>>
ambiguous_block_expr_parse: Lock<FxHashMap<Span, Span>>
Contains the spans of block expressions that could have been incomplete based on the operation token that followed it, but that the parser cannot identify without further analysis.
Methods
impl ParseSess
[src]
pub fn new(file_path_mapping: FilePathMapping) -> Self
[src]
pub fn with_span_handler(
handler: Handler,
source_map: Lrc<SourceMap>
) -> ParseSess
[src]
handler: Handler,
source_map: Lrc<SourceMap>
) -> ParseSess
pub fn source_map(&self) -> &SourceMap
[src]
pub fn buffer_lint<S: Into<MultiSpan>>(
&self,
lint_id: BufferedEarlyLintId,
span: S,
id: NodeId,
msg: &str
)
[src]
&self,
lint_id: BufferedEarlyLintId,
span: S,
id: NodeId,
msg: &str
)
pub fn expr_parentheses_needed(
&self,
err: &mut DiagnosticBuilder,
span: Span,
alt_snippet: Option<String>
)
[src]
&self,
err: &mut DiagnosticBuilder,
span: Span,
alt_snippet: Option<String>
)
Extend an error with a suggestion to wrap an expression with parentheses to allow the parser to continue parsing the following operation as part of the same expression.
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<E> SpecializationError for E
[src]
default fn not_found<S, T>(
trait_name: &'static str,
method_name: &'static str
) -> E where
T: ?Sized,
[src]
trait_name: &'static str,
method_name: &'static str
) -> E where
T: ?Sized,
impl<T> Send for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Sync for T where
T: ?Sized,
[src]
T: ?Sized,