]> git.lizzy.rs Git - rust.git/commitdiff
auto merge of #18160 : koshlo/rust/to-source-fix, r=alexcrichton
authorbors <bors@rust-lang.org>
Sun, 19 Oct 2014 23:32:07 +0000 (23:32 +0000)
committerbors <bors@rust-lang.org>
Sun, 19 Oct 2014 23:32:07 +0000 (23:32 +0000)
Fix for issue #18091

The problem seems to be that `ast_util::int_ty_to_string` takes unsigned number, and no one adds `-` to result string. I've fixed it by putting `-` before result string using `format!`.

I've also added `test_signed_int_to_string()` to check if implementation is valid.


Trivial merge