rbs icon indicating copy to clipboard operation
rbs copied to clipboard

Deprecate top-level float

Open sampersand opened this issue 2 months ago • 3 comments

This PR deprecates the top-level float type, as it's mostly pointless and is not an implicit conversion (like all the other top-level alias types).

Most places you'd expect to use it (eg Math functions) actually require Numeric & _ToF. There's only a few minor edge-cases in the stdlib that use floats directly (eg Regexp.timeout=), but they can instead use _ToF.

sampersand avatar Oct 31 '25 04:10 sampersand

cc @ParadoxV5 , @soutaro , and @ksss . Thoughts?

sampersand avatar Oct 31 '25 05:10 sampersand

Thoughts?

Perhaps we could use a convenience alias for Numeric & _ToF, then.

ParadoxV5 avatar Oct 31 '25 05:10 ParadoxV5

It'd only really be used in Math, which already does this with type double = Numeric & _ToF

sampersand avatar Oct 31 '25 05:10 sampersand