mirror of
https://github.com/php/php-src.git
synced 2024-11-24 10:24:11 +08:00
22 lines
303 B
PHP
22 lines
303 B
PHP
--TEST--
|
|
Bug #70215 (Segfault when invoke is static)
|
|
--FILE--
|
|
<?php
|
|
|
|
class A {
|
|
public static function __invoke() {
|
|
echo __CLASS__;
|
|
}
|
|
}
|
|
|
|
class B extends A { }
|
|
|
|
$b = new B;
|
|
|
|
$b();
|
|
|
|
?>
|
|
--EXPECTF--
|
|
Warning: The magic method __invoke() must have public visibility and cannot be static in %s on line %d
|
|
A
|