mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 16:24:46 +00:00
syntax: slight improvement in fidelity of printing tokens. Still not great.
This commit is contained in:
parent
40bd686e70
commit
ce24d37759
@ -150,14 +150,12 @@ fn to_str(in: @ident_interner, t: Token) -> ~str {
|
||||
~"'" + char::escape_default(c as char) + ~"'"
|
||||
}
|
||||
LIT_INT(i, t) => {
|
||||
int::to_str(i as int, 10u) + ast_util::int_ty_to_str(t)
|
||||
i.to_str() + ast_util::int_ty_to_str(t)
|
||||
}
|
||||
LIT_UINT(u, t) => {
|
||||
uint::to_str(u as uint, 10u) + ast_util::uint_ty_to_str(t)
|
||||
}
|
||||
LIT_INT_UNSUFFIXED(i) => {
|
||||
int::to_str(i as int, 10u)
|
||||
u.to_str() + ast_util::uint_ty_to_str(t)
|
||||
}
|
||||
LIT_INT_UNSUFFIXED(i) => { i.to_str() }
|
||||
LIT_FLOAT(s, t) => {
|
||||
let mut body = *in.get(s);
|
||||
if body.ends_with(~".") {
|
||||
|
Loading…
Reference in New Issue
Block a user