opendylan icon indicating copy to clipboard operation
opendylan copied to clipboard

Add float formatter, %f, to format

Open cgay opened this issue 6 years ago • 2 comments

format should have a way to format floating point numbers. I assume we'll use %f. Depends on #225 and ties into #1158.

cgay avatar Mar 04 '19 02:03 cgay

The io library in Gwydion Dylan has an implementation of this, at https://github.com/dylan-hackers/gwydion/blame/master/common/io/format.dylan

Note for future reference that the current state-of-the-art in implementing float-to-string is Ryū, described in https://dl.acm.org/citation.cfm?id=3192369

housel avatar Mar 10 '19 03:03 housel

For additional reference, https://github.com/jk-jeon/dragonbox is said to be faster than Ryū.

housel avatar Sep 28 '20 17:09 housel