> But I think it needs more correctness tests.

Indeed!

My quick and dirty test showed these results:
    
    
    [fraction = $result: dtoa(result)]
     7 /  3 = 2.333333333333333: 2.3333333333333337
    10 /  3 = 3.333333333333333: 3.3333333333333337
     7 /  6 = 1.166666666666667: 1.1666666666666668
    10 /  9 = 1.111111111111111: 1.1111111111111112
    16 /  9 = 1.777777777777778: 1.7777777777777777
    20 /  9 = 2.222222222222222: 2.2222222222222225
    22 /  9 = 2.444444444444445: 2.4444444444444448
     2 / 11 = 0.1818181818181818: 0.18181818181818183
     1 / 22 = 0.04545454545454546: 0.045454545454545459
    
    
    Run

It should be noted that `$result` shows one digit less than `dtoa(result)`, and 
it is only in that last digit that `dtoa` produces "crazy" results (in these 
few handpicked examples).

Reply via email to