зеркало из https://github.com/github/ruby.git
* numeric.c (flo_to_s): use the exponential form if the integer part
is longer than or equal DBL_DIG. [ruby-dev:45960] [ruby-trunk - Bug #6741] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
e985c49e64
Коммит
0e2aa330ec
|
@ -1,3 +1,9 @@
|
|||
Mon Jul 16 22:50:41 2012 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* numeric.c (flo_to_s): use the exponential form if the integer part
|
||||
is longer than or equal DBL_DIG.
|
||||
[ruby-dev:45960] [ruby-trunk - Bug #6741]
|
||||
|
||||
Mon Jul 16 22:01:00 2012 Ayumu AIZAWA <ayumu.aizawa@gmail.com>
|
||||
|
||||
* ext/readline/readline.c: fixed docs. [Bug #6740][ruby-core:46501]
|
||||
|
|
|
@ -662,7 +662,7 @@ flo_to_s(VALUE flt)
|
|||
buf[decpt] = '.';
|
||||
rb_str_cat(s, buf, digs + 1);
|
||||
}
|
||||
else if (decpt - digs < float_dig) {
|
||||
else if (decpt <= DBL_DIG) {
|
||||
long len;
|
||||
char *ptr;
|
||||
rb_str_cat(s, buf, digs);
|
||||
|
|
Загрузка…
Ссылка в новой задаче