From: <wsf...@us...> - 2008-09-18 13:16:52
|
Revision: 10868 http://swig.svn.sourceforge.net/swig/?rev=10868&view=rev Author: wsfulton Date: 2008-09-18 20:16:50 +0000 (Thu, 18 Sep 2008) Log Message: ----------- minor typo and formatting improvements Modified Paths: -------------- trunk/Lib/python/pybuffer.i trunk/Lib/python/pyerrors.swg trunk/Lib/python/pyhead.swg Modified: trunk/Lib/python/pybuffer.i =================================================================== --- trunk/Lib/python/pybuffer.i 2008-09-18 20:16:03 UTC (rev 10867) +++ trunk/Lib/python/pybuffer.i 2008-09-18 20:16:50 UTC (rev 10868) @@ -1,4 +1,4 @@ -/* Impelementing buffer protocol typemaps */ +/* Implementing buffer protocol typemaps */ /* %pybuffer_mutable_binary(TYPEMAP, SIZE) * Modified: trunk/Lib/python/pyerrors.swg =================================================================== --- trunk/Lib/python/pyerrors.swg 2008-09-18 20:16:03 UTC (rev 10867) +++ trunk/Lib/python/pyerrors.swg 2008-09-18 20:16:50 UTC (rev 10868) @@ -59,8 +59,7 @@ PyErr_Clear(); Py_XINCREF(type); - PyErr_Format(type, "%s %s", - SWIG_Python_str_AsChar(old_str), mesg); + PyErr_Format(type, "%s %s", SWIG_Python_str_AsChar(old_str), mesg); Py_DECREF(old_str); Py_DECREF(value); } else { Modified: trunk/Lib/python/pyhead.swg =================================================================== --- trunk/Lib/python/pyhead.swg 2008-09-18 20:16:03 UTC (rev 10867) +++ trunk/Lib/python/pyhead.swg 2008-09-18 20:16:50 UTC (rev 10868) @@ -2,19 +2,18 @@ #if PY_VERSION_HEX >= 0x03000000 #define PyClass_Check(obj) PyObject_IsInstance(obj, (PyObject *)&PyType_Type) - #define PyInt_Check(x) PyLong_Check(x) #define PyInt_AsLong(x) PyLong_AsLong(x) #define PyInt_FromLong(x) PyLong_FromLong(x) - #define PyString_Format(fmt, args) PyUnicode_Format(fmt, args) + #endif #ifndef Py_TYPE # define Py_TYPE(op) ((op)->ob_type) #endif -/* SWIG APIs for compatibility of boht Python 2 & 3 */ +/* SWIG APIs for compatibility of both Python 2 & 3 */ #if PY_VERSION_HEX >= 0x03000000 # define SWIG_Python_str_FromFormat PyUnicode_FromFormat @@ -88,6 +87,7 @@ # define PyObject_GenericGetAttr 0 # endif #endif + /* Py_NotImplemented is defined in 2.1 and up. */ #if PY_VERSION_HEX < 0x02010000 # ifndef Py_NotImplemented @@ -95,7 +95,6 @@ # endif #endif - /* A crude PyString_AsStringAndSize implementation for old Pythons */ #if PY_VERSION_HEX < 0x02010000 # ifndef PyString_AsStringAndSize @@ -110,7 +109,6 @@ # endif #endif - /* PyBool_FromLong for old Pythons */ #if PY_VERSION_HEX < 0x02030000 static This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |