diff options
| author | bors <bors@rust-lang.org> | 2014-04-13 10:36:47 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-04-13 10:36:47 -0700 |
| commit | 465109df62d8d12f9b12c7d4f425999774e1c151 (patch) | |
| tree | 54f37bd1c7fb1645e786a38ef06ee71871ce2542 /src/libsyntax/parse | |
| parent | 7240fad25e309ae5d8ebfb2b7544a1e62f9382fe (diff) | |
| parent | 888517df4d5c83423f9722b32c6fe1b113b58208 (diff) | |
| download | rust-465109df62d8d12f9b12c7d4f425999774e1c151.tar.gz rust-465109df62d8d12f9b12c7d4f425999774e1c151.zip | |
auto merge of #13452 : Ryman/rust/fix_uint_as_u, r=alexcrichton
Fixes #13359.
Diffstat (limited to 'src/libsyntax/parse')
| -rw-r--r-- | src/libsyntax/parse/token.rs | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/libsyntax/parse/token.rs b/src/libsyntax/parse/token.rs index baade21d942..101c748b1ec 100644 --- a/src/libsyntax/parse/token.rs +++ b/src/libsyntax/parse/token.rs @@ -201,12 +201,8 @@ pub fn to_str(t: &Token) -> ~str { res.push_char('\''); res.into_owned() } - LIT_INT(i, t) => { - i.to_str() + ast_util::int_ty_to_str(t) - } - LIT_UINT(u, t) => { - u.to_str() + ast_util::uint_ty_to_str(t) - } + LIT_INT(i, t) => ast_util::int_ty_to_str(t, Some(i)), + LIT_UINT(u, t) => ast_util::uint_ty_to_str(t, Some(u)), LIT_INT_UNSUFFIXED(i) => { i.to_str() } LIT_FLOAT(s, t) => { let mut body = StrBuf::from_str(get_ident(s).get()); |
