Function rustc_parse::maybe_file_to_stream
source · pub fn maybe_file_to_stream(
sess: &ParseSess,
source_file: Lrc<SourceFile>,
override_span: Option<Span>
) -> Result<(TokenStream, Vec<UnmatchedBrace>), Vec<Diagnostic>>
Expand description
Given a source file, produces a sequence of token trees. Returns any buffered errors from parsing the token stream.