ned14/nedtries — pull request #7 by Sebbyastian (2014-12-11 07:23:01+00:00)
Title: Code cleanup and subtle bug fixes

* Pervasive: Use CHAR_BIT from instead of __CHAR_BIT__ (this fixes builds on implementations that don't have __CHAR_BIT__).
* #31: Include for SIZE_MAX.
* #192, pervasive: Remove/substitute allbits1 for SIZE_MAX in .
* #197: Check that size_t has more than 16 bits before shifting it by 16 bits (avoid undefined behaviour on systems where sizeof(x)*CHAR_BIT == 16) (use preprocessor if branching overhead is a concern here)
* #198: Check that size_t h.s more than 32 bits before shifting it by 32 bits (guarantee predictable behaviour for systems that have strange size_t sizes such as 48 bits) (use preprocessor if branching overhead is a concern here)
* #202, #203: Replace magic numbers with required constants (from ) that commonly have those values.