I also think that Float and Double are not ideal type names but I also agree 
with many of the concerns that have been raised.


Why not simply use (the existing) Float32 and Float64 while keeping everything 
else equal?

So as a first step we could encourage the use of Float32/Float64 over 
Float/Double:
Make Float/Double typealiases for Float32/Float64 instead of the reverse which 
is true today
Use Float32/Float64 in documentation and example code
Perhaps add a note to the documentation for Float/Double that the 
Float32/Float64 types should be preferred
...

This would not break any existing code and I think would be a positive change 
in the long term.
Also this might have a better chance to be accepted as a proposal and by the 
community at large.

Making Float32/Float64 the officially preferred types should still help their 
adoption a lot without the pains involved in removing Float/Double.

And the deprecation and eventual removal of Float/Double could still be 
considered separately either now or down the road if people actually adopt 
Float32/Float64. Also migration would be very simple in this case (and 
stragglers could simply create their own Float/Double typealiases).


- Janosch

_______________________________________________
swift-evolution mailing list
[email protected]
https://lists.swift.org/mailman/listinfo/swift-evolution

Reply via email to