Fix numeric types for IDs.
Include stdint.h for uintptr_t.