You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, trying to use a non-integer will only perform the operation on the integer portion of the number:
import{Apply,Numbers}from"hotscript";typeDoubleHalf=Apply<Numbers.Mul,[0.5,2]>;// evaluates to 0typeDoubleTwoPointFive=Apply<Numbers.Mul,[2.5,2]>;// evaluates to 4
It's not supported indeed. Would it be possible ? Definitely.
Is it worth implementing it ? depends on use cases.
The already implemented number features are already borderline useful.
To answer the question, i was not planning on adding floating point capability.
But PR are welcomed.
I would however suggest anyone interested in implementing it to Implement it Using a Floats namespace to not have impact on the Numbers perf
Currently, trying to use a non-integer will only perform the operation on the integer portion of the number:
Playground link
Couldn't find any mention of it on this repo, so just was wondering if this is unintentional, planned to be implemented, or not being added?
The text was updated successfully, but these errors were encountered: