Closed MisterDA closed 1 month ago
@MisterDA Feel free to add a Changes entry if you wish.
@MisterDA Feel free to add a Changes entry if you wish.
Done, thanks.
The original code is at https://gist.github.com/rygorous/2156668. I've reported this issue.
Cherry-picked to 5.2 as a safe bug fix in 9e54469 .
Compilers likely behave and cast (15-127) to unsigned, but strictly speaking this is UB and needs to be explicit, otherwise the compiler may warn or wrongly optimize.
The warning is raised by clang. I've checked that the assembly code generated stays the same.