#18682 [NEW]: for loop with floats causes roundup problem
| From: | webmaster at hackquest dot com | Date: | Wed, 31 Jul 2002 20:36:35 +0000 |
| Subject: | #18682 [NEW]: for loop with floats causes roundup problem | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-15711@lists.php.net to get a copy of this message | ||
From: webmaster@hackquest.com
Operating system: Linux
PHP version: 4.2.2
PHP Bug Type: Variables related
Bug description: for loop with floats causes roundup problem
for ($i = 1.0; $i >= 0; $i -= 0.05)
Will produce the line:
..
..
0.1
0.05
The 0 is missing, obviously its rounded to below zero somehow, and then
gets discarded.
--
Edit bug report at http://bugs.php.net/?id=18682&edit=1
--
Fixed in CVS: http://bugs.php.net/fix.php?id=18682&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=18682&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=18682&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=18682&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=18682&r=support
Expected behavior: http://bugs.php.net/fix.php?id=18682&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=18682&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=18682&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=18682&r=globals