Skip to content

Commit 9e5bddd

Browse files
committed
Merge branch 'PHP-8.0' into PHP-8.1
* PHP-8.0: Fixed bug #81626
2 parents 3bea159 + 9e25c4b commit 9e5bddd

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

Zend/tests/bug81626.phpt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
--TEST--
2+
Bug #81626: Error on use static:: in __сallStatic() wrapped to Closure::fromCallable()
3+
--FILE--
4+
<?php
5+
class TestClass {
6+
public static bool $wasCalled = false;
7+
public static function __callStatic(string $name, array $args): string
8+
{
9+
static::$wasCalled = true;
10+
return 'ok';
11+
}
12+
}
13+
$closure = Closure::fromCallable([TestClass::class, 'foo']);
14+
var_dump($closure());
15+
?>
16+
--EXPECT--
17+
string(2) "ok"

0 commit comments

Comments
 (0)