mirror of
https://github.com/python/cpython.git
synced 2025-07-23 19:25:40 +00:00
Completely disable the declarations for malloc() and friends. Use
#ifdef though, so if you still need these for a really backwards compiler you know what to do.
This commit is contained in:
parent
0078aaf950
commit
ab589b945e
1 changed files with 3 additions and 2 deletions
|
@ -67,12 +67,13 @@ extern "C" {
|
||||||
#pragma lib_export on
|
#pragma lib_export on
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef HAVE_STDLIB_H
|
/* The following should never be necessary */
|
||||||
|
#ifdef NEED_TO_DECLARE_MALLOC_AND_FRIEND
|
||||||
extern ANY *malloc Py_PROTO((size_t));
|
extern ANY *malloc Py_PROTO((size_t));
|
||||||
extern ANY *calloc Py_PROTO((size_t, size_t));
|
extern ANY *calloc Py_PROTO((size_t, size_t));
|
||||||
extern ANY *realloc Py_PROTO((ANY *, size_t));
|
extern ANY *realloc Py_PROTO((ANY *, size_t));
|
||||||
extern void free Py_PROTO((ANY *)); /* XXX sometimes int on Unix old systems */
|
extern void free Py_PROTO((ANY *)); /* XXX sometimes int on Unix old systems */
|
||||||
#endif /* !HAVE_STDLIB */
|
#endif
|
||||||
|
|
||||||
#ifndef NULL
|
#ifndef NULL
|
||||||
#define NULL ((ANY *)0)
|
#define NULL ((ANY *)0)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue