Commit 99259f9c authored by Shane Hathaway's avatar Shane Hathaway

Silenced gcc warnings.

- Removed ASSIGN macros, never used.

- Changed empty parameter list to "void".
parent b7f4dc58
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
DAMAGE. DAMAGE.
$Id: ComputedAttribute.c,v 1.4 2001/01/23 14:37:20 jim Exp $ $Id: ComputedAttribute.c,v 1.5 2001/05/23 18:28:33 shane Exp $
If you have questions regarding this software, If you have questions regarding this software,
contact: contact:
...@@ -46,16 +46,7 @@ ...@@ -46,16 +46,7 @@
*/ */
#include "ExtensionClass.h" #include "ExtensionClass.h"
static void
PyVar_Assign(PyObject **v, PyObject *e)
{
Py_XDECREF(*v);
*v=e;
}
#define ASSIGN(V,E) PyVar_Assign(&(V),(E))
#define UNLESS(E) if(!(E)) #define UNLESS(E) if(!(E))
#define UNLESS_ASSIGN(V,E) ASSIGN(V,E); UNLESS(V)
#define OBJECT(O) ((PyObject*)(O)) #define OBJECT(O) ((PyObject*)(O))
typedef struct { typedef struct {
...@@ -142,10 +133,10 @@ static struct PyMethodDef methods[] = { ...@@ -142,10 +133,10 @@ static struct PyMethodDef methods[] = {
}; };
void void
initComputedAttribute() initComputedAttribute(void)
{ {
PyObject *m, *d; PyObject *m, *d;
char *rev="$Revision: 1.4 $"; char *rev="$Revision: 1.5 $";
UNLESS(ExtensionClassImported) return; UNLESS(ExtensionClassImported) return;
...@@ -155,7 +146,7 @@ initComputedAttribute() ...@@ -155,7 +146,7 @@ initComputedAttribute()
/* Create the module and add the functions */ /* Create the module and add the functions */
m = Py_InitModule4("ComputedAttribute", methods, m = Py_InitModule4("ComputedAttribute", methods,
"Provide Computed Attributes\n\n" "Provide Computed Attributes\n\n"
"$Id: ComputedAttribute.c,v 1.4 2001/01/23 14:37:20 jim Exp $\n", "$Id: ComputedAttribute.c,v 1.5 2001/05/23 18:28:33 shane Exp $\n",
OBJECT(NULL),PYTHON_API_VERSION); OBJECT(NULL),PYTHON_API_VERSION);
d = PyModule_GetDict(m); d = PyModule_GetDict(m);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment