+#if PHP_VERSION_ID >= 80000
+zval *php_pq_object_write_prop(zend_object *object, zend_string *member, zval *value, void **cache_slot)
+{
+ if (SUCCESS != php_pq_object_write_prop_ex(object, member, value)) {
+ return zend_std_write_property(object, member, value, cache_slot);
+ }
+ return value;
+}
+#elif PHP_VERSION_ID >= 70400
+zval *php_pq_object_write_prop(zval *object, zval *member, zval *value, void **cache_slot)
+{
+ zend_string *member_str = zval_get_string(member);
+ if (SUCCESS != php_pq_object_write_prop_ex(Z_OBJ_P(object), member_str, value)) {
+ value = zend_std_write_property(object, member, value, cache_slot);
+ }
+ zend_string_release(member_str);
+ return value;
+}
+#else
+void php_pq_object_write_prop(zval *object, zval *member, zval *value, void **cache_slot)
+{
+ zend_string *member_str = zval_get_string(member);
+ if (SUCCESS != php_pq_object_write_prop_ex(Z_OBJ_P(object), member_str, value)) {
+ zend_std_write_property(object, member, value, cache_slot);
+ }
+ zend_string_release(member_str);
+}
+#endif
+
+#if PHP_VERSION_ID >= 80000
+zval *php_pq_object_get_prop_ptr_null(zend_object *object, zend_string *member, int type, void **cache_slot)
+{
+ return NULL;
+}
+#else
+zval *php_pq_object_get_prop_ptr_null(zval *object, zval *member, int type, void **cache_slot)
+{
+ return NULL;
+}
+#endif