summaryrefslogtreecommitdiff
path: root/Source/Modules/php.cxx
diff options
context:
space:
mode:
authorOlly Betts <olly@survex.com>2021-12-17 09:37:00 +1300
committerOlly Betts <olly@survex.com>2021-12-17 09:37:00 +1300
commit6253583809d66f399cacba251f55bbda6487b6cc (patch)
treef650a02862e7da8f02f799098731ab0f12f82d95 /Source/Modules/php.cxx
parent9ffa15b3075dc2cf79e9425de0c8653680317e69 (diff)
downloadswig-6253583809d66f399cacba251f55bbda6487b6cc.tar.gz
Rename php_fetch_object with swig_ prefix
We shouldn't be using symbols starting `php` as that risks collisions with future symbols defined by PHP.
Diffstat (limited to 'Source/Modules/php.cxx')
-rw-r--r--Source/Modules/php.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx
index 732f1ce61..e778a735d 100644
--- a/Source/Modules/php.cxx
+++ b/Source/Modules/php.cxx
@@ -134,7 +134,7 @@ static void print_creation_free_wrapper(Node *n) {
Printf(s, " swig_object_wrapper *obj = 0;\n");
Printf(s, " if (!object)\n");
Printf(s, " return;\n");
- Printf(s, " obj = php_fetch_object(object);\n");
+ Printf(s, " obj = swig_php_fetch_object(object);\n");
Printf(s, " zend_object_std_dtor(&obj->std);\n");
@@ -198,7 +198,7 @@ static void SwigPHP_emit_pointer_type_registrations() {
Append(s_wrappers, "#if PHP_MAJOR_VERSION < 8\n");
Printf(s_wrappers, " swig_object_wrapper *obj = SWIG_Z_FETCH_OBJ_P(z);\n");
Append(s_wrappers, "#else\n");
- Printf(s_wrappers, " swig_object_wrapper *obj = php_fetch_object(zobj);\n");
+ Printf(s_wrappers, " swig_object_wrapper *obj = swig_php_fetch_object(zobj);\n");
Append(s_wrappers, "#endif\n");
Printv(s_wrappers, " sprintf(buf, \"SWIGPointer(%p,owned=%d)\", obj->ptr, obj->newobject);\n", NIL);
Printf(s_wrappers, " ZVAL_STRING(retval, buf);\n");