Add types for character position and byte position in the codemap

This commit is contained in:
Brian Anderson
2012-11-12 19:32:48 -08:00
parent 9ecf86343a
commit f67bfe9738
22 changed files with 285 additions and 161 deletions

View File

@@ -205,7 +205,7 @@ impl Parser: parser_common {
if self.token == token::GT {
self.bump();
} else if self.token == token::BINOP(token::SHR) {
self.swap(token::GT, self.span.lo + 1u, self.span.hi);
self.swap(token::GT, self.span.lo + CharPos(1u), self.span.hi);
} else {
let mut s: ~str = ~"expected `";
s += token_to_str(self.reader, token::GT);