Cannot make non abstract method %s::%s() abstract in class %s¶
Description¶
Once a method has a body, it cannot be made abstract
again.
On the other hand, the child class may be abstract, while the parent class is not. It just means that new methods must be implemented.
Example¶
<?php
class X {
function foo() {}
}
abstract class Y extends X {
abstract function foo();
}
?>
Solutions¶
Make the child class the parent.
Change the name of the abstract method in the child class.
Remove the abstract option in the child class.
Add the abstract option in the parent class.
Make the method abstract in the parent class.