1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Bug fix: '-' should not be counted as a digit(to_s(n) format).

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4364 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
shigek 2003-08-10 14:28:08 +00:00
parent 923044bba2
commit b2385db896

View file

@ -3109,10 +3109,8 @@ VpFormatSt(char *psz,S_INT fFmt)
for(i = 0; i < ie; ++i) {
ch = psz[i];
if(!ch) break;
if(ch == '.') {
nf = 0;
continue;
}
if(ch=='-' || ch=='+') continue;
if(ch == '.') { nf = 0;continue;}
if(ch == 'E') break;
nf++;
if(nf > fFmt) {