stdlib.h: Remove guards around aligned_alloc.

While FreeBSD and glibc feature-guard it, they also feature-guard
a lot of other things that we don't, and musl does not guard it,
so it seems more than safe enough to leave it unguarded.

Fixes compilation errors with GCC 11. (The other possible solution
was including features.h in more places, but this seems simpler.)
This commit is contained in:
Augustin Cavalier
2021-11-16 15:13:29 -05:00
parent 3bdd837e4e
commit 1e541d3127
+1 -3
View File
@@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 Haiku, Inc. All Rights Reserved.
* Copyright 2002-2021 Haiku, Inc. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef _STDLIB_H_
@@ -49,9 +49,7 @@ extern void *calloc(size_t numElements, size_t size);
extern void free(void *pointer);
extern void *malloc(size_t size);
extern int posix_memalign(void **_pointer, size_t alignment, size_t size);
#ifdef _ISOC11_SOURCE
extern void *aligned_alloc(size_t alignment, size_t size) _ALIGNED_BY_ARG(1);
#endif
extern void *realloc(void *oldPointer, size_t newSize);
/* process termination */