提交 3b93fba8 编写于 作者: B Bruce Momjian

Remove plpython casts C source code casts:

It removes last remaining casts inside struct definitions.
Such usage is bad practice, as it hides problems from compiler.

Reason for the cast is popular practice in some circles
to define functions as foo(MyObj *) instead of foo(PyObject *)
thus avoiding a local variable inside functions and make
direct calling easier.  As pl/python does not use such style,
the casts were unnecessary from the start.


Marko Kreen
上级 8f296ebe
/**********************************************************************
* plpython.c - python as a procedural language for PostgreSQL
*
* $PostgreSQL: pgsql/src/pl/plpython/plpython.c,v 1.99 2007/04/03 15:50:58 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plpython/plpython.c,v 1.100 2007/04/04 17:28:11 momjian Exp $
*
*********************************************************************
*/
......@@ -1994,9 +1994,9 @@ static PyTypeObject PLy_PlanType = {
/*
* methods
*/
(destructor) PLy_plan_dealloc, /* tp_dealloc */
PLy_plan_dealloc, /* tp_dealloc */
0, /* tp_print */
(getattrfunc) PLy_plan_getattr, /* tp_getattr */
PLy_plan_getattr, /* tp_getattr */
0, /* tp_setattr */
0, /* tp_compare */
0, /* tp_repr */
......@@ -2038,9 +2038,9 @@ static PyTypeObject PLy_ResultType = {
/*
* methods
*/
(destructor) PLy_result_dealloc, /* tp_dealloc */
PLy_result_dealloc, /* tp_dealloc */
0, /* tp_print */
(getattrfunc) PLy_result_getattr, /* tp_getattr */
PLy_result_getattr, /* tp_getattr */
0, /* tp_setattr */
0, /* tp_compare */
0, /* tp_repr */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册