[][src]Function rustc_parse::new_parser_from_file

pub fn new_parser_from_file<'a>(
    sess: &'a ParseSess,
    path: &Path,
    sp: Option<Span>
) -> Parser<'a>
⚙️ This is an internal compiler API. (rustc_private)

This crate is being loaded from the sysroot, a permanently unstable location for private compiler dependencies. It is not intended for general use. Prefer using a public version of this crate from crates.io via Cargo.toml.

Creates a new parser, handling errors as appropriate if the file doesn't exist. If a span is given, that is used on an error as the as the source of the problem.