3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class BaseItem { } abstract class BaseCollection { abstract function test(BaseItem $base); } class RealItem { } class RealCollection extends BaseCollection { function test(RealItem $real) { } }
Output for 5.4.0 - 5.4.30
Fatal error: Declaration of RealCollection::test() must be compatible with BaseCollection::test(BaseItem $base) in /in/jc4Kq on line 4
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Fatal error: Declaration of RealCollection::test() must be compatible with that of BaseCollection::test() in /in/jc4Kq on line 4
Process exited with code 255.