syntax: Fix printing INT64_MIN

Integers are always parsed as a u64 in libsyntax, but they're stored as i64. The
parser and pretty printer both printed an i64 instead of u64, sometimes
introducing an extra negative sign.
This commit is contained in:
Alex Crichton 2014-05-10 20:16:51 -07:00
parent 1237530452
commit 042c8ae40e
6 changed files with 39 additions and 25 deletions

View file

@ -16,4 +16,5 @@ pub fn main() {
assert_eq!(-2147483648i32 - 1i32, 2147483647i32);
assert_eq!(-9223372036854775808i64 - 1i64, 9223372036854775807i64);
assert_eq!(-9223372036854775808 - 1, 9223372036854775807);
}