[Python-checkins] r43111 - in python/branches/p3yk: Include/Python.h Modules/cstubs RISCOS/Modules/riscosmodule.c

neal.norwitz python-checkins at python.org
Fri Mar 17 10:00:01 CET 2006


Author: neal.norwitz
Date: Fri Mar 17 10:00:00 2006
New Revision: 43111

Modified:
   python/branches/p3yk/Include/Python.h
   python/branches/p3yk/Modules/cstubs
   python/branches/p3yk/RISCOS/Modules/riscosmodule.c
Log:
Remove PyArg_NoArgs() and PyArg_GetInt()

Modified: python/branches/p3yk/Include/Python.h
==============================================================================
--- python/branches/p3yk/Include/Python.h	(original)
+++ python/branches/p3yk/Include/Python.h	Fri Mar 17 10:00:00 2006
@@ -131,13 +131,6 @@
 /* _Py_Mangle is defined in compile.c */
 PyAPI_FUNC(PyObject*) _Py_Mangle(PyObject *p, PyObject *name);
 
-/* PyArg_GetInt is deprecated and should not be used, use PyArg_Parse(). */
-#define PyArg_GetInt(v, a)	PyArg_Parse((v), "i", (a))
-
-/* PyArg_NoArgs should not be necessary.
-   Set ml_flags in the PyMethodDef to METH_NOARGS. */
-#define PyArg_NoArgs(v)		PyArg_Parse(v, "")
-
 /* Convert a possibly signed character to a nonnegative int */
 /* XXX This assumes characters are 8 bits wide */
 #ifdef __CHAR_UNSIGNED__

Modified: python/branches/p3yk/Modules/cstubs
==============================================================================
--- python/branches/p3yk/Modules/cstubs	(original)
+++ python/branches/p3yk/Modules/cstubs	Fri Mar 17 10:00:00 2006
@@ -472,8 +472,6 @@
 {
 	PyObject *v, *w;
 	int i, nhits, n;
-	if (!PyArg_NoArgs(args))
-		return NULL;
 	if (pickbuffer == NULL) {
 		PyErr_SetString(PyExc_RuntimeError,
 			"endpick/endselect: not in pick/select mode");

Modified: python/branches/p3yk/RISCOS/Modules/riscosmodule.c
==============================================================================
--- python/branches/p3yk/RISCOS/Modules/riscosmodule.c	(original)
+++ python/branches/p3yk/RISCOS/Modules/riscosmodule.c	Fri Mar 17 10:00:00 2006
@@ -79,7 +79,7 @@
 }
 
 static PyObject *riscos_getcwd(PyObject *self,PyObject *args)
-{ if(!PyArg_NoArgs(args)) return NULL;
+{ 
   return canon("@");
 }
 
@@ -354,7 +354,7 @@
 	{"system",	riscos_system},
 	{"rmdir",	riscos_remove},
 	{"chdir",	riscos_chdir},
-	{"getcwd",	riscos_getcwd},
+	{"getcwd",	riscos_getcwd, METH_NOARGS},
 	{"expand",      riscos_expand},
 	{"mkdir",	riscos_mkdir,1},
 	{"listdir",	riscos_listdir},


More information about the Python-checkins mailing list