TypePHP 编译器 https://swoole.com/aot/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

32 lines
504 B

<?php
namespace Demo\Dispatch {
class ChildOverrideNs extends ParentBaseNs
{
public function bar(): void
{
echo "Child\n";
}
}
class ParentBaseNs
{
public function run(): void
{
$this->bar();
}
public function bar(): void
{
echo "Parent\n";
}
}
}
namespace {
function main(): void
{
$o = new Demo\Dispatch\ChildOverrideNs();
$o->run();
}
}