mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:47:44 +00:00
LibC: The standard C library needs to be able to build as pure C.
Looks like we can't use those comfy C++ attributes in this code then.
This commit is contained in:
parent
3b42db0b4c
commit
cbfd416279
4 changed files with 14 additions and 12 deletions
|
@ -9,16 +9,16 @@ __BEGIN_DECLS
|
|||
#define EXIT_FAILURE 1
|
||||
#define MB_CUR_MAX 1
|
||||
|
||||
[[gnu::malloc, gnu::alloc_size(1)]] void* malloc(size_t);
|
||||
[[gnu::malloc, gnu::alloc_size(1, 2)]] void* calloc(size_t nmemb, size_t);
|
||||
__attribute__((malloc)) __attribute__((alloc_size(1))) void* malloc(size_t);
|
||||
__attribute__((malloc)) __attribute__((alloc_size(1, 2))) void* calloc(size_t nmemb, size_t);
|
||||
void free(void*);
|
||||
void* realloc(void *ptr, size_t);
|
||||
char* getenv(const char* name);
|
||||
int atoi(const char*);
|
||||
long atol(const char*);
|
||||
void qsort(void* base, size_t nmemb, size_t size, int (*compar)(const void *, const void *));
|
||||
[[noreturn]] void exit(int status);
|
||||
[[noreturn]] void abort();
|
||||
__attribute__((noreturn)) void exit(int status);
|
||||
__attribute__((noreturn)) void abort();
|
||||
char* ptsname(int fd);
|
||||
int ptsname_r(int fd, char* buffer, size_t);
|
||||
int abs(int);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue