libsyntax: change Parser::unexpected_last to take &Token

This commit is contained in:
Erick Tryzelaar
2013-02-24 21:20:50 -08:00
parent 28691a0852
commit 34c02a6c0e
2 changed files with 4 additions and 4 deletions

View File

@@ -51,12 +51,12 @@ pub fn token_to_str(reader: reader, token: &token::Token) -> ~str {
}
pub impl Parser {
fn unexpected_last(t: token::Token) -> ! {
fn unexpected_last(t: &token::Token) -> ! {
self.span_fatal(
*self.last_span,
fmt!(
"unexpected token: `%s`",
token_to_str(self.reader, &t)
token_to_str(self.reader, t)
)
);
}