mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
befe10fd21
Refactor the zend_is_callable implementation to check callability at a particular frame (this is an implementation detail for now, but could be exposed in the API if useful). Pick the first parent user frame as the one to check.
26 lines
459 B
PHP
26 lines
459 B
PHP
--TEST--
|
|
Bug #78770: Incorrect callability check inside internal methods
|
|
--SKIPIF--
|
|
<?php
|
|
if (!extension_loaded("intl")) die("skip requires intl");
|
|
?>
|
|
--FILE--
|
|
<?php
|
|
|
|
class Test {
|
|
public function method() {
|
|
IntlChar::enumCharTypes([$this, 'privateMethod']);
|
|
IntlChar::enumCharTypes('self::privateMethod');
|
|
}
|
|
|
|
private function privateMethod($start, $end, $name) {
|
|
}
|
|
}
|
|
|
|
(new Test)->method();
|
|
|
|
?>
|
|
===DONE===
|
|
--EXPECT--
|
|
===DONE===
|