note 81825 deleted from function.round by danbrown
| From: | danbrown@php.net | Date: | Sun, 17 May 2009 16:15:01 +0000 |
| Subject: | note 81825 deleted from function.round by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-154775@lists.php.net to get a copy of this message | ||
Note Submitter: timpleasenospamshaw at mailnospam dot usa dot com
----
After reading all of the notes for this page, I suggest that any casual PHP coder beware. Please
consult someone with an actual understanding of floating point issues before developing a serious
application, such as one dealing with money in any form.
Also, in the note I just posted, I suggested using integers for monetary values. PHP does not
currently support 64 bit integers on platforms where int is normally 32 bits, so watch out for
overflow occuring near $2 million or $20 million, depending on whether the integers represent mils
or cents. I believe it may be possible for PHP to give an incorrect result without an error
condition for some integer overflow conditions.
Again, please see
http://www.php.net/float