Add typecast to a test
(1 << x) where "x" is a uint64_t would treat "1" as an int and roll over at 32-bits. Typecasting "1" to uint64_t eliminates that and supports a full 64-bit value.
Please register or sign in to comment
(1 << x) where "x" is a uint64_t would treat "1" as an int and roll over at 32-bits. Typecasting "1" to uint64_t eliminates that and supports a full 64-bit value.