summaryrefslogtreecommitdiffstats
path: root/42.patch
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2021-03-15 07:00:17 +0100
committerRemi Collet <remi@remirepo.net>2021-03-15 07:00:17 +0100
commit8f7e291b6a838d1ebd80a4abbdce9a33d8f43948 (patch)
treeedb2c9cab3091816d782c5cd58c43c4616c5ff59 /42.patch
parentc51c14e6e33561aad1ce7795a3a25a6ec4d568b9 (diff)
update to 1.2.0RC1
drop all patches merged upstream
Diffstat (limited to '42.patch')
-rw-r--r--42.patch107
1 files changed, 0 insertions, 107 deletions
diff --git a/42.patch b/42.patch
deleted file mode 100644
index 9d20a9a..0000000
--- a/42.patch
+++ /dev/null
@@ -1,107 +0,0 @@
-From 23c34676e88ed6aef5fc6b6484a65abb554aa11a Mon Sep 17 00:00:00 2001
-From: Remi Collet <remi@remirepo.net>
-Date: Tue, 25 Aug 2020 10:51:51 +0200
-Subject: [PATCH 1/2] adapt for PHP 8 and missing arginfo
-
----
- fann.c | 7 ++-----
- fann_connection.c | 9 ++++++---
- php_fann.h | 2 +-
- 3 files changed, 9 insertions(+), 9 deletions(-)
-
-diff --git a/fann.c b/fann.c
-index da5f307..a5c2e68 100644
---- a/fann.c
-+++ b/fann.c
-@@ -1445,9 +1445,7 @@ static int php_fann_callback(struct fann *ann, struct fann_train_data *train,
-
- /* set fci */
- PHPC_FCALL_RETVAL(fci, retval);
-- fci.params = PHPC_FCALL_PARAMS_NAME(callback);
-- fci.param_count = 6;
-- fci.no_separation = 0;
-+ PHPC_FCALL_FCI_INIT(fci, callback, 6, 0);
-
- if (zend_call_function(&fci, &fci_cache TSRMLS_CC) != SUCCESS || PHPC_VAL_ISUNDEF(retval)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "An error occurred while invoking the user callback");
-@@ -2173,8 +2171,7 @@ PHP_FUNCTION(fann_create_train_from_callback)
- /* set fci */
- PHPC_FCALL_RETVAL(fci, retval);
- fci.params = PHPC_FCALL_PARAMS_NAME(callback);
-- fci.param_count = 3;
-- fci.no_separation = 0;
-+ PHPC_FCALL_FCI_INIT(fci, callback, 3, 0);
-
- /* call callback for each data */
- for (i = 0; i < num_data; i++) {
-diff --git a/fann_connection.c b/fann_connection.c
-index 4fe818b..7580054 100644
---- a/fann_connection.c
-+++ b/fann_connection.c
-@@ -108,13 +108,16 @@ ZEND_END_ARG_INFO()
- ZEND_BEGIN_ARG_INFO(arginfo_fannconnection_set_weight, 0)
- ZEND_ARG_INFO(0, weight)
- ZEND_END_ARG_INFO()
-+
-+ZEND_BEGIN_ARG_INFO(arginfo_fannconnection_void, 0)
-+ZEND_END_ARG_INFO()
- /* }}} */
-
- static zend_function_entry fannconnection_funcs[] = {
- PHP_ME(FANNConnection, __construct, arginfo_fannconnection___construct, ZEND_ACC_CTOR | ZEND_ACC_PUBLIC)
-- PHP_ME(FANNConnection, getFromNeuron, NULL, ZEND_ACC_PUBLIC)
-- PHP_ME(FANNConnection, getToNeuron, NULL, ZEND_ACC_PUBLIC)
-- PHP_ME(FANNConnection, getWeight, NULL, ZEND_ACC_PUBLIC)
-+ PHP_ME(FANNConnection, getFromNeuron, arginfo_fannconnection_void, ZEND_ACC_PUBLIC)
-+ PHP_ME(FANNConnection, getToNeuron, arginfo_fannconnection_void, ZEND_ACC_PUBLIC)
-+ PHP_ME(FANNConnection, getWeight, arginfo_fannconnection_void, ZEND_ACC_PUBLIC)
- PHP_ME(FANNConnection, setWeight, arginfo_fannconnection_set_weight, ZEND_ACC_PUBLIC)
- PHPC_FE_END
- };
-diff --git a/php_fann.h b/php_fann.h
-index 3197a67..7008c04 100644
---- a/php_fann.h
-+++ b/php_fann.h
-@@ -232,7 +232,7 @@ PHP_FANN_API extern zend_class_entry *php_fann_FANNConnection_class;
- /* macros for dealing with FANNConnection properties */
- #define PHP_FANN_CONN_PROP_NAME(__name) __name, sizeof(__name)-1
- #define PHP_FANN_CONN_PROP_UPDATE(__type, __obj, __name, __value) \
-- zend_update_property_##__type(php_fann_FANNConnection_class, (__obj), \
-+ zend_update_property_##__type(php_fann_FANNConnection_class, PHPC_OBJ_FOR_PROP(__obj), \
- PHP_FANN_CONN_PROP_NAME(__name), (__value) TSRMLS_CC)
- #define PHP_FANN_CONN_PROP_DECLARE(__type, __name) \
- zend_declare_property_##__type(php_fann_FANNConnection_class, PHP_FANN_CONN_PROP_NAME(__name), \
-
-From f7bfc3d254d24f35462d03ccce19597bae593d38 Mon Sep 17 00:00:00 2001
-From: Remi Collet <remi@remirepo.net>
-Date: Wed, 2 Sep 2020 09:39:38 +0200
-Subject: [PATCH 2/2] fix for 8.0.0beta3
-
----
- fann.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/fann.c b/fann.c
-index a5c2e68..68dd96b 100644
---- a/fann.c
-+++ b/fann.c
-@@ -1618,7 +1618,8 @@ PHP_FUNCTION(fann_destroy)
- return;
- }
-
-- RETURN_BOOL(PHPC_RES_CLOSE(z_ann) == SUCCESS);
-+ PHPC_RES_CLOSE(z_ann);
-+ RETURN_TRUE;
- }
- /* }}} */
-
-@@ -2242,7 +2243,8 @@ PHP_FUNCTION(fann_destroy_train)
- return;
- }
-
-- RETURN_BOOL(PHPC_RES_CLOSE(z_train_data) == SUCCESS);
-+ PHPC_RES_CLOSE(z_train_data);
-+ RETURN_TRUE;
- }
- /* }}} */
-