Function syntex_syntax::parse::parse_item_from_source_str [] [src]

pub fn parse_item_from_source_str<'a>(name: String, source: String, cfg: CrateConfig, sess: &'a ParseSess) -> PResult<'a, Option<P<Item>>>

Parses an item.

Returns Ok(Some(item)) when successful, Ok(None) when no item was found, andErr when a syntax error occurred.