- Output for 8.1.0 - 8.1.28, 8.2.0 - 8.2.19, 8.3.0 - 8.3.7
- foo is called bar is called
<?php
function foo($x){
echo "foo is called" . PHP_EOL;
}
class Foo {
function bar($x)
{
echo "bar is called" . PHP_EOL;
}
}
foo(10, 20);
(new Foo())->bar(20, 30);