[RFA:] stdint.h take 2: Add INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX

Joseph S. Myers joseph@codesourcery.com
Fri Apr 24 21:58:00 GMT 2009


On Fri, 24 Apr 2009, Gregory Pietsch wrote:

> Would
> 
> #define UINTPTR_MAX ((PTRDIFF_MAX << 1) + 1)

No, that expression has a signed type and UINTPTR_MAX must have an 
unsigned type, namely uintptr_t, and must also be usable in preprocessor 
#if expressions so you can't use a cast to uintptr_t.

-- 
Joseph S. Myers
joseph@codesourcery.com



More information about the Newlib mailing list