Convert implicit cast from `long` to `double` to a `static_cast`
Summary: This code implicitly casts a `long` to `double` but a `double` can not accurately represent an integer above `2^53` as the mantissa only stores that many digits. At `2^53 + 1` `double`s increment by `2`. Thus this cast is lossy. Though, casting a single value `LONG_MAX` to a `double` is and being off by one doesn't cause any harm here. Reviewed By: ispeters Differential Revision: D25654006 fbshipit-source-id: 3d84092f1786d7879dd48d73af8edbbc80bb3585
Showing
Please register or sign in to comment