From 7a2d6112d95d5944b60b78232a5a75570db6e76a Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Sat, 2 Aug 1997 02:41:13 +0000 Subject: Add cast to PyInt_AS_LONG macro, as suggested by Marc Lemburg. --- Include/intobject.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Include/intobject.h b/Include/intobject.h index d9fd68f..cd66f75 100644 --- a/Include/intobject.h +++ b/Include/intobject.h @@ -83,7 +83,7 @@ extern DL_IMPORT(PyIntObject) _Py_ZeroStruct, _Py_TrueStruct; /* Don't use these #define Py_True ((PyObject *) &_Py_TrueStruct) /* Macro, trading safety for speed */ -#define PyInt_AS_LONG(op) ((op)->ob_ival) +#define PyInt_AS_LONG(op) (((PyIntObject *)(op))->ob_ival) #ifdef __cplusplus } -- cgit v0.12