And why is that a problem again? Float64 is integer-safe until 253 and in the edge case that you need a larger integer you got typed arrays (Uint64Array and Int64Array). JavaScript's Number type even works seamlessly with bitwise operators (|, &, ^, etc.), truncating itself to int32 in those cases. What are you missing from it?
7
u/maweki Aug 26 '20
You do know that JS only has a single number type, right?! There is no promotion going on.