summaryrefslogtreecommitdiffstats
path: root/bitset-php82.patch
blob: 4851cf0936c110edfe26e3cd64437dc0328c2da8 (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
From 39a70cb32da68b14a704f8a9c41a911029596e70 Mon Sep 17 00:00:00 2001
From: Remi Collet <remi@remirepo.net>
Date: Fri, 9 Sep 2022 16:16:18 +0200
Subject: [PATCH] Fix __toString  prototype with PHP 8.2

---
 bitset.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/bitset.c b/bitset.c
index 82765e1..a744d69 100644
--- a/bitset.c
+++ b/bitset.c
@@ -118,7 +118,11 @@ ZEND_END_ARG_INFO()
 ZEND_BEGIN_ARG_INFO(arginfo_bitset_xorop, 0)
 ZEND_END_ARG_INFO()
 
+#if PHP_VERSION_ID >= 80200
+ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_bitset___tostring, 0, 0, IS_STRING, 0)
+#else
 ZEND_BEGIN_ARG_INFO(arginfo_bitset___tostring, 0)
+#endif
 ZEND_END_ARG_INFO()
 
 ZEND_BEGIN_ARG_INFO(arginfo_bitset_getrawvalue, 0)