blob: 3fe0456175f091ec33708ccd4343e7dc869c4215 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
--TEST--
Incompatible context call (non-internal function)
--FILE--
<?php
class A {
function foo() { var_dump(get_class($this)); }
}
class B {
function bar() { A::foo(); }
}
$b = new B;
try {
$b->bar();
} catch (Throwable $e) {
echo "Exception: " . $e->getMessage() . "\n";
}
?>
--EXPECT--
Exception: Non-static method A::foo() cannot be called statically
|