ruby-changes:29445
From: akr <ko1@a...>
Date: Thu, 20 Jun 2013 22:27:24 +0900 (JST)
Subject: [ruby-changes:29445] akr:r41497 (trunk): * bignum.c (dump_bignum): Use SIZEOF_BDIGITS.
akr 2013-06-20 22:27:15 +0900 (Thu, 20 Jun 2013) New Revision: 41497 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=41497 Log: * bignum.c (dump_bignum): Use SIZEOF_BDIGITS. Modified files: trunk/ChangeLog trunk/bignum.c Index: ChangeLog =================================================================== --- ChangeLog (revision 41496) +++ ChangeLog (revision 41497) @@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Thu Jun 20 22:24:41 2013 Tanaka Akira <akr@f...> + + * bignum.c (dump_bignum): Use SIZEOF_BDIGITS. + Thu Jun 20 22:22:46 2013 Tanaka Akira <akr@f...> * bignum.c (big2ulong): Change the return type to unsigned long. Index: bignum.c =================================================================== --- bignum.c (revision 41496) +++ bignum.c (revision 41497) @@ -87,7 +87,7 @@ dump_bignum(VALUE x) https://github.com/ruby/ruby/blob/trunk/bignum.c#L87 long i; printf("%c0x0", RBIGNUM_SIGN(x) ? '+' : '-'); for (i = RBIGNUM_LEN(x); i--; ) { - printf("_%08"PRIxBDIGIT, BDIGITS(x)[i]); + printf("_%0*"PRIxBDIGIT, SIZEOF_BDIGITS*2, BDIGITS(x)[i]); } printf(", len=%lu", RBIGNUM_LEN(x)); puts(""); -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/