HomeFreeBSD

Add a utility macro for converting 64-bit pointers to native pointers.

Description

Add a utility macro for converting 64-bit pointers to native pointers.

Right now we're casting uint64_t's to native pointers. This isn't
causing any problems right now, but if we want to provide a 32-bit
compatibility layer that works on 64-bit systems as well, this will
cause problems. Casting a uint32_t to a 64-bit pointer throws a compiler
error.

Introduce a TO_PTR() macro that casts the value to uintptr_t before
casting it to a pointer.

Details

Provenance
edAuthored on
Parents
rS304557: Move the linker script from cloudabi64/ to cloudabi/.
Branches
Unknown
Tags
Unknown