mirror of
https://github.com/google/brotli.git
synced 2026-09-22 06:35:52 +00:00
platform.h (lines 552-553): _BitScanReverse #320
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @dejanyy on GitHub (May 22, 2020).
On lines 552-553 of platform.h we have:
uint32_t msb;
_BitScanReverse(&msb, x);
I think "uint32_t msb;" is wrong. Certainly doesn't compile with MS Visual Studio 2017. Changing that line to "unsigned long msb;" seems to fix the problem. See:
https://docs.microsoft.com/en-us/cpp/intrinsics/bitscanreverse-bitscanreverse64?view=vs-2019