Move token-to-string functions into print::pprust

This commit is contained in:
Brendan Zabarauskas
2014-10-28 11:05:28 +11:00
parent cd049591a2
commit 665ad9c175
5 changed files with 108 additions and 106 deletions

View File

@@ -78,6 +78,7 @@ use parse::token::InternedString;
use parse::token::{keywords, special_idents};
use parse::token;
use parse::{new_sub_parser_from_file, ParseSess};
use print::pprust;
use ptr::P;
use owned_slice::OwnedSlice;
@@ -394,7 +395,7 @@ impl<'a> Parser<'a> {
/// Convert a token to a string using self's reader
pub fn token_to_string(token: &token::Token) -> String {
token::to_string(token)
pprust::token_to_string(token)
}
/// Convert the current token to a string using self's reader