From: Lisandro Dalcin Date: Mon, 16 Aug 2010 18:47:34 +0000 (-0300) Subject: silent GCC warnings with Py<2.5 X-Git-Tag: 0.13~12 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=19cf712cbf1abe4534351ac857180695b83a294a;p=cython.git silent GCC warnings with Py<2.5 --- diff --git a/Cython/Compiler/ExprNodes.py b/Cython/Compiler/ExprNodes.py index 87f04ee4..c635d668 100755 --- a/Cython/Compiler/ExprNodes.py +++ b/Cython/Compiler/ExprNodes.py @@ -7518,7 +7518,7 @@ static PyObject *%(binding_cfunc)s_descr_get(PyObject *func, PyObject *obj, PyOb int %(binding_cfunc)s_init(void) { %(binding_cfunc)s_type = PyCFunction_Type; - %(binding_cfunc)s_type.tp_name = "cython_binding_builtin_function_or_method"; + %(binding_cfunc)s_type.tp_name = __Pyx_NAMESTR("cython_binding_builtin_function_or_method"); %(binding_cfunc)s_type.tp_dealloc = (destructor)%(binding_cfunc)s_dealloc; %(binding_cfunc)s_type.tp_descr_get = %(binding_cfunc)s_descr_get; if (PyType_Ready(&%(binding_cfunc)s_type) < 0) { diff --git a/Cython/Compiler/ModuleNode.py b/Cython/Compiler/ModuleNode.py index 204dd8e3..f143a62e 100644 --- a/Cython/Compiler/ModuleNode.py +++ b/Cython/Compiler/ModuleNode.py @@ -2048,7 +2048,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode): if func.is_special and func.wrapperbase_cname: code.putln("{"); code.putln( - 'PyObject *wrapper = PyObject_GetAttrString((PyObject *)&%s, "%s"); %s' % ( + 'PyObject *wrapper = __Pyx_GetAttrString((PyObject *)&%s, "%s"); %s' % ( typeobj_cname, func.name, code.error_goto_if_null('wrapper', entry.pos)));