Remove all usage of @ast::Crate

This commit is contained in:
Alex Crichton
2013-09-27 19:46:09 -07:00
parent 22ef7e72f4
commit 7b18976f08
19 changed files with 174 additions and 223 deletions

View File

@@ -47,14 +47,14 @@ fn with_error_checking_parse<T>(s: @str, f: &fn(&mut Parser) -> T) -> T {
}
// parse a string, return a crate.
pub fn string_to_crate (source_str : @str) -> @ast::Crate {
pub fn string_to_crate (source_str : @str) -> ast::Crate {
do with_error_checking_parse(source_str) |p| {
p.parse_crate_mod()
}
}
// parse a string, return a crate and the ParseSess
pub fn string_to_crate_and_sess (source_str : @str) -> (@ast::Crate,@mut ParseSess) {
pub fn string_to_crate_and_sess (source_str : @str) -> (ast::Crate,@mut ParseSess) {
let (p,ps) = string_to_parser_and_sess(source_str);
(p.parse_crate_mod(),ps)
}