[NFC][libc++] Suppress "warning: ignoring return value"

According to the comment on the next line
it's expected behaviour.
This commit is contained in:
Vitaly Buka 2021-02-26 14:29:06 -08:00
parent e29063b16e
commit 3744ba24dc
1 changed files with 1 additions and 1 deletions

View File

@ -314,7 +314,7 @@ void* __libcpp_aligned_alloc(std::size_t __alignment, std::size_t __size) {
return ::_aligned_malloc(__size, __alignment);
#else
void* __result = nullptr;
::posix_memalign(&__result, __alignment, __size);
(void)::posix_memalign(&__result, __alignment, __size);
// If posix_memalign fails, __result is unmodified so we still return `nullptr`.
return __result;
#endif