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
1 changed files with 2 additions and 4 deletions

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) {