LWN.net Logo

PHP: a fractal of bad design (fuzzy notepad)

PHP: a fractal of bad design (fuzzy notepad)

Posted Apr 18, 2012 23:34 UTC (Wed) by cmccabe (guest, #60281)
In reply to: PHP: a fractal of bad design (fuzzy notepad) by juliank
Parent article: PHP: a fractal of bad design (fuzzy notepad)

I doubt that using floats rather than 64-bit integers is saving you any typing.


(Log in to post comments)

PHP: a fractal of bad design (fuzzy notepad)

Posted Apr 19, 2012 8:15 UTC (Thu) by juliank (subscriber, #45896) [Link]

It doesn't when counting, but since I have to convert to double later on anyway, I can just count in double as well.

I could perhaps rewrite the human-readable size formatting to use integers (i.e. print B,KiB,MiB,GiB, TiB), but if I want precision after the period, things will start to get more complicated. And I usually want that precision.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds