pub fn string_to_crate (source_str: String) -> Option<ast::Crate> {
    with_error_checking_parse(source_str.clone(), |p| {
        use std::result::Result::{Ok, Err};
        use syntex_syntax::diagnostic::FatalError;
        match p.parse_crate_mod() {
            Ok(e) => Some(e),
            Err(FatalError) => {
                debug!("unable to parse crate. Returning None |{}|", source_str);
                None
            }
        }
    })
}
// parse a string, return a crate.
parse a string, return a crate.
parse a string return a crate .
pub fn string_to_crate (source_str: String) -> Option<ast::Crate> {
    with_error_checking_parse(source_str.clone(), |p| {
        use std::result::Result::{Ok, Err};
        use syntex_syntax::diagnostic::FatalError;
        match p.parse_crate_mod() {
            Ok(e) => Some(e),
            Err(FatalError) => {
                debug!("unable to parse crate. Returning None |{}|", source_str);
                None
            }
        }
    })
}
pub fn string_to_crate ( source_str : String ) -> Option < ast :: Crate > { with_error_checking_parse ( source_str . clone ( ) , | p | { use std :: result :: Result :: { Ok , Err } ; use syntex_syntax :: diagnostic :: FatalError ; match p . parse_crate_mod ( ) { Ok ( e ) => Some ( e ) , Err ( FatalError ) => { debug ! ( " " source_str ) ; None } } } ) }
parse a string, return a crate.
parse a string return a crate .
source_str
String