...
Any valid pointer to void can be converted to intptr_t or uintptr_t and back with no change in value (see INT36-EX2). The C Standard guarantees that a pointer to void may be converted to or from a pointer to any object type and and back again and that the result must compare equal to the original pointer. Consequently, converting directly from a char * pointer to a uintptr_t, as in this compliant solution, is allowed on implementations that support the uintptr_t type.
...