ANSIfications: fix empty arglists, and remove the checks for

'HAVE_STDARG_PROTOTYPES' (consider it true, remove false branch)
This commit is contained in:
Thomas Wouters 2000-07-22 23:30:03 +00:00
parent 7889010731
commit 5f37591a16
6 changed files with 3 additions and 34 deletions

View File

@ -27,15 +27,9 @@ DL_IMPORT(PyObject *) PyEval_CallObject(PyObject *, PyObject *);
#define PyEval_CallObject(func,arg) \
PyEval_CallObjectWithKeywords(func, arg, (PyObject *)NULL)
#ifdef HAVE_STDARG_PROTOTYPES
DL_IMPORT(PyObject *) PyEval_CallFunction(PyObject *obj, char *format, ...);
DL_IMPORT(PyObject *) PyEval_CallMethod(PyObject *obj,
char *methodname, char *format, ...);
#else
/* Better to have no prototypes at all for varargs functions in this case */
DL_IMPORT(PyObject *) PyEval_CallFunction();
DL_IMPORT(PyObject *) PyEval_CallMethod();
#endif
DL_IMPORT(PyObject *) PyEval_GetBuiltins(void);
DL_IMPORT(PyObject *) PyEval_GetGlobals(void);

View File

@ -35,12 +35,12 @@ extern DL_IMPORT(PyObject *)_PyImport_FixupExtension(char *, char *);
struct _inittab {
char *name;
void (*initfunc)();
void (*initfunc)(void);
};
extern DL_IMPORT(struct _inittab *) PyImport_Inittab;
extern DL_IMPORT(int) PyImport_AppendInittab(char *name, void (*initfunc)());
extern DL_IMPORT(int) PyImport_AppendInittab(char *name, void (*initfunc)(void));
extern DL_IMPORT(int) PyImport_ExtendInittab(struct _inittab *newtab);
struct _frozen {

View File

@ -16,8 +16,6 @@ extern "C" {
/* Module support interface */
#ifdef HAVE_STDARG_PROTOTYPES
#include <stdarg.h>
extern DL_IMPORT(int) PyArg_Parse(PyObject *, char *, ...);
@ -26,17 +24,6 @@ extern DL_IMPORT(int) PyArg_ParseTupleAndKeywords(PyObject *, PyObject *,
char *, char **, ...);
extern DL_IMPORT(PyObject *) Py_BuildValue(char *, ...);
#else
#include <varargs.h>
/* Better to have no prototypes at all for varargs functions in this case */
extern DL_IMPORT(int) PyArg_Parse();
extern DL_IMPORT(int) PyArg_ParseTuple();
extern DL_IMPORT(PyObject *) Py_BuildValue();
#endif
extern DL_IMPORT(int) PyArg_VaParse(PyObject *, char *, va_list);
extern DL_IMPORT(PyObject *) Py_VaBuildValue(char *, va_list);

View File

@ -35,14 +35,8 @@ redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#include "pydebug.h"
#ifdef HAVE_STDARG_PROTOTYPES
DL_IMPORT(void) PySys_WriteStdout(const char *format, ...);
DL_IMPORT(void) PySys_WriteStderr(const char *format, ...);
#else
/* Better to have no prototypes at all for varargs functions in this case */
DL_IMPORT(void) PySys_WriteStdout();
DL_IMPORT(void) PySys_WriteStderr();
#endif
#define addarc _Py_addarc
#define addbit _Py_addbit

View File

@ -22,14 +22,8 @@ DL_IMPORT(FILE *) PySys_GetFile(char *, FILE *);
DL_IMPORT(void) PySys_SetArgv(int, char **);
DL_IMPORT(void) PySys_SetPath(char *);
#ifdef HAVE_STDARG_PROTOTYPES
DL_IMPORT(void) PySys_WriteStdout(const char *format, ...);
DL_IMPORT(void) PySys_WriteStderr(const char *format, ...);
#else
/* Better to have no prototypes at all for varargs functions in this case */
DL_IMPORT(void) PySys_WriteStdout();
DL_IMPORT(void) PySys_WriteStderr();
#endif
extern DL_IMPORT(PyObject *) _PySys_TraceFunc, *_PySys_ProfileFunc;
extern DL_IMPORT(int) _PySys_CheckInterval;

View File

@ -376,7 +376,7 @@ extern DL_IMPORT(int) PyUnicode_AsWideChar(
*/
extern DL_IMPORT(const char*) PyUnicode_GetDefaultEncoding();
extern DL_IMPORT(const char*) PyUnicode_GetDefaultEncoding(void);
/* Sets the currently active default encoding.