syntax: Fix semicolon printing. Closes #3036
This commit is contained in:
parent
416584d339
commit
ef29f7ff36
2 changed files with 7 additions and 1 deletions
|
@ -136,7 +136,7 @@ fn to_str(in: interner<@~str>, t: token) -> ~str {
|
||||||
DOT { ~"." }
|
DOT { ~"." }
|
||||||
ELLIPSIS { ~"..." }
|
ELLIPSIS { ~"..." }
|
||||||
COMMA { ~"," }
|
COMMA { ~"," }
|
||||||
SEMI { ~"" }
|
SEMI { ~";" }
|
||||||
COLON { ~":" }
|
COLON { ~":" }
|
||||||
MOD_SEP { ~"::" }
|
MOD_SEP { ~"::" }
|
||||||
RARROW { ~"->" }
|
RARROW { ~"->" }
|
||||||
|
|
6
src/test/compile-fail/issue-3036.rs
Normal file
6
src/test/compile-fail/issue-3036.rs
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
// Testing that semicolon tokens are printed correctly in errors
|
||||||
|
|
||||||
|
fn main()
|
||||||
|
{
|
||||||
|
let x = 3
|
||||||
|
} //~ ERROR: expected `;` but found `}`
|
Loading…
Add table
Add a link
Reference in a new issue