abstract class base { public function inherited() { $this->overridden(); } private function overridden() { echo 'base'; } } class child extends base { private function overridden() { echo 'child'; } } $test = new child(); $test->inherited();
这里为什么会输出base,我的认知是输出child啊。。
阿晨1998