Function wrench::align_ptr¶
Defined in File memory_utils.hpp
Function Documentation¶
-
auto wrench::align_ptr (const void *ptr, size_t alignment) noexcept -> void * Returns a pointer with an address aligned to
alignment. This will fail at runtime if thealignemntis not a power of two.- Parameters
ptr: The pointer to align.alignment: The alignment to ensure.