module Float::Printer

Overview

Float::Printer is based on Grisu3 algorithm described in the 2004 paper "Printing Floating-Point Numbers Quickly and Accurately with Integers" by Florian Loitsch.

Extended Modules

Defined in:

float/printer/cached_powers.cr
float/printer.cr

Constant Summary

BUFFER_SIZE = 128

Instance Method Summary

Instance Method Detail

def print(v : Float64 | Float32, io : IO) #

Converts Float v to a string representation and prints it onto io

It is used by Float64#to_s and it is probably not necessary to use this directly.


View source