diff options
Diffstat (limited to 'src/comp/syntax/parse')
| -rw-r--r-- | src/comp/syntax/parse/lexer.rs | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/comp/syntax/parse/lexer.rs b/src/comp/syntax/parse/lexer.rs index 988c46b6b88..fa147faa1cc 100644 --- a/src/comp/syntax/parse/lexer.rs +++ b/src/comp/syntax/parse/lexer.rs @@ -326,8 +326,7 @@ fn scan_numeric_escape(rdr: &reader, n_hex_digits: uint) -> char { rdr.bump(); if !is_hex_digit(n) { rdr.err( - istr::from_estr( - #fmt["illegal numeric character escape: %d", n as int])); + #ifmt["illegal numeric character escape: %d", n as int]); fail; } accum_int *= 16; @@ -471,8 +470,8 @@ fn next_token_inner(rdr: &reader) -> token::token { 'U' { c2 = scan_numeric_escape(rdr, 8u); } c2 { rdr.err( - istr::from_estr(#fmt["unknown character escape: %d", - c2 as int])); + #ifmt["unknown character escape: %d", + c2 as int]); fail; } } @@ -512,8 +511,8 @@ fn next_token_inner(rdr: &reader) -> token::token { } c2 { rdr.err( - istr::from_estr(#fmt["unknown string escape: %d", - c2 as int])); + #ifmt["unknown string escape: %d", + c2 as int]); fail; } } @@ -553,7 +552,7 @@ fn next_token_inner(rdr: &reader) -> token::token { '%' { ret binop(rdr, token::PERCENT); } c { rdr.err( - istr::from_estr(#fmt["unkown start of token: %d", c as int])); + #ifmt["unkown start of token: %d", c as int]); fail; } } @@ -654,7 +653,7 @@ fn read_block_comment(rdr: &reader, code_to_the_left: bool) -> cmnt { let curr_line = ~"/*"; let level: int = 1; while level > 0 { - log #fmt["=== block comment level %d", level]; + log #ifmt["=== block comment level %d", level]; if rdr.is_eof() { rdr.err(~"unterminated block comment"); fail; } if rdr.curr() == '\n' { trim_whitespace_prefix_and_push_line(lines, curr_line, col); |
