summaryrefslogtreecommitdiffstats
path: root/472.patch
blob: 78afdf48890700adf1c1d61e684b8cf24b4b0247 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
From a92bf68eeed33392f0a117aec9750ad4c7b4358c Mon Sep 17 00:00:00 2001
From: Michael Wallner <mike@php.net>
Date: Mon, 18 Jan 2021 14:24:28 +0100
Subject: [PATCH] fix php8 arginfo

---
 php_memcached.stub.php         | 12 ++++++------
 php_memcached_arginfo.h        | 22 +++++++++++-----------
 php_memcached_legacy_arginfo.h |  2 +-
 3 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/php_memcached.stub.php b/php_memcached.stub.php
index 6b84c5b..5a735b5 100644
--- a/php_memcached.stub.php
+++ b/php_memcached.stub.php
@@ -8,17 +8,17 @@
 
 class Memcached {
 
-	public function __construct(string $persistent_id=NULL, callable $callback=NULL, string $connection_str=NULL) {}
+	public function __construct(string $persistent_id=null, callable $callback=null, string $connection_str=null) {}
 
 	public function getResultCode(): int {}
 	public function getResultMessage(): string {}
 
-	public function get(string $key, callable $cache_cb=NULL, int $get_flags=0): mixed {}
-	public function getByKey(string $server_key, string $key, callable $cache_cb=NULL, int $get_flags=0): mixed {}
+	public function get(string $key, callable $cache_cb=null, int $get_flags=0): mixed {}
+	public function getByKey(string $server_key, string $key, callable $cache_cb=null, int $get_flags=0): mixed {}
 	public function getMulti(array $keys, int $get_flags=0): false|array {}
 	public function getMultiByKey(string $server_key, array $keys, int $get_flags=0): false|array {}
-	public function getDelayed(array $keys, bool $with_cas=NULL, callable $value_cb=NULL): bool {}
-	public function getDelayedByKey(string $server_key, array $keys, bool $with_cas=NULL, callable $value_cb=NULL): bool {}
+	public function getDelayed(array $keys, bool $with_cas=false, callable $value_cb=null): bool {}
+	public function getDelayedByKey(string $server_key, array $keys, bool $with_cas=false, callable $value_cb=null): bool {}
 	public function fetch(): false|array {}
 	public function fetchAll(): false|array {}
 
@@ -64,7 +64,7 @@ public function getLastErrorCode(): int {}
 	public function getLastErrorErrno(): int {}
 	public function getLastDisconnectedServer(): false|array {}
 
-	public function getStats(string $type=NULL): false|array {}
+	public function getStats(string $type=null): false|array {}
 	public function getVersion(): false|array {}
 	public function getAllKeys(): false|array {}
 
diff --git a/php_memcached_arginfo.h b/php_memcached_arginfo.h
index 6b05cf4..4c8a684 100644
--- a/php_memcached_arginfo.h
+++ b/php_memcached_arginfo.h
@@ -1,10 +1,10 @@
 /* This is a generated file, edit the .stub.php file instead.
- * Stub hash: 8ce11ff45ccb2b1c765e5f313305f539ca3fa4f6 */
+ * Stub hash: 573d35c5c6b6c397943e0f8ab9c505e2f4ce9e34 */
 
 ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Memcached___construct, 0, 0, 0)
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, persistent_id, IS_STRING, 0, "NULL")
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, callback, IS_CALLABLE, 0, "NULL")
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, connection_str, IS_STRING, 0, "NULL")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, persistent_id, IS_STRING, 1, "null")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, callback, IS_CALLABLE, 1, "null")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, connection_str, IS_STRING, 1, "null")
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Memcached_getResultCode, 0, 0, IS_LONG, 0)
@@ -15,14 +15,14 @@ ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Memcached_get, 0, 1, IS_MIXED, 0)
 	ZEND_ARG_TYPE_INFO(0, key, IS_STRING, 0)
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, cache_cb, IS_CALLABLE, 0, "NULL")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, cache_cb, IS_CALLABLE, 1, "null")
 	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, get_flags, IS_LONG, 0, "0")
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Memcached_getByKey, 0, 2, IS_MIXED, 0)
 	ZEND_ARG_TYPE_INFO(0, server_key, IS_STRING, 0)
 	ZEND_ARG_TYPE_INFO(0, key, IS_STRING, 0)
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, cache_cb, IS_CALLABLE, 0, "NULL")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, cache_cb, IS_CALLABLE, 1, "null")
 	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, get_flags, IS_LONG, 0, "0")
 ZEND_END_ARG_INFO()
 
@@ -39,15 +39,15 @@ ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Memcached_getDelayed, 0, 1, _IS_BOOL, 0)
 	ZEND_ARG_TYPE_INFO(0, keys, IS_ARRAY, 0)
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, with_cas, _IS_BOOL, 0, "NULL")
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, value_cb, IS_CALLABLE, 0, "NULL")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, with_cas, _IS_BOOL, 0, "false")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, value_cb, IS_CALLABLE, 1, "null")
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Memcached_getDelayedByKey, 0, 2, _IS_BOOL, 0)
 	ZEND_ARG_TYPE_INFO(0, server_key, IS_STRING, 0)
 	ZEND_ARG_TYPE_INFO(0, keys, IS_ARRAY, 0)
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, with_cas, _IS_BOOL, 0, "NULL")
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, value_cb, IS_CALLABLE, 0, "NULL")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, with_cas, _IS_BOOL, 0, "false")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, value_cb, IS_CALLABLE, 1, "null")
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_class_Memcached_fetch, 0, 0, MAY_BE_FALSE|MAY_BE_ARRAY)
@@ -202,7 +202,7 @@ ZEND_END_ARG_INFO()
 #define arginfo_class_Memcached_getLastDisconnectedServer arginfo_class_Memcached_fetch
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_class_Memcached_getStats, 0, 0, MAY_BE_FALSE|MAY_BE_ARRAY)
-	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, type, IS_STRING, 0, "NULL")
+	ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, type, IS_STRING, 1, "null")
 ZEND_END_ARG_INFO()
 
 #define arginfo_class_Memcached_getVersion arginfo_class_Memcached_fetch
diff --git a/php_memcached_legacy_arginfo.h b/php_memcached_legacy_arginfo.h
index c942616..a615e3a 100644
--- a/php_memcached_legacy_arginfo.h
+++ b/php_memcached_legacy_arginfo.h
@@ -1,5 +1,5 @@
 /* This is a generated file, edit the .stub.php file instead.
- * Stub hash: 8ce11ff45ccb2b1c765e5f313305f539ca3fa4f6 */
+ * Stub hash: 573d35c5c6b6c397943e0f8ab9c505e2f4ce9e34 */
 
 ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Memcached___construct, 0, 0, 0)
 	ZEND_ARG_INFO(0, persistent_id)