Skip to content

Commit 24899ec

Browse files
committed
Fix PHP 8 support
1 parent 6d4958d commit 24899ec

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

scalar_objects.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ static zval *get_zval_ptr_real(
6565
const zend_execute_data *execute_data, int type
6666
) {
6767
#if PHP_VERSION_ID >= 80000
68-
zval *zv = zend_get_zval_ptr(opline, op_type, node, execute_data, type);
68+
zval *zv = zend_get_zval_ptr(opline, op_type, node, execute_data);
6969
#elif PHP_VERSION_ID >= 70300
7070
zend_free_op should_free;
7171
zval *zv = zend_get_zval_ptr(opline, op_type, node, execute_data, &should_free, type);
@@ -114,7 +114,11 @@ static ZEND_NAMED_FUNCTION(scalar_objects_indirection_func)
114114
#endif
115115
fci.param_count = ZEND_NUM_ARGS() + 1;
116116
fci.params = params;
117+
#if PHP_VERSION_ID >= 80000
118+
fci.named_params = NULL;
119+
#else
117120
fci.no_separation = 1;
121+
#endif
118122

119123
#if PHP_VERSION_ID < 70300
120124
fcc.initialized = 1;

tests/visibility.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,4 @@ $str->prot();
2828
Public
2929
Protected
3030

31-
Fatal error: Call to protected method StringHandler::prot() from context '' in %s on line %d
31+
Fatal error: Call to protected method StringHandler::prot() from %s in %s on line %d

0 commit comments

Comments
 (0)