Base class and inherited setup
class A
{
static public function meow(string $x,string $y="default"){}
}
class B extends A
{
static public function meow(string $y="default"){}
}
Output
PHP Fatal error: Declaration of B::meow(string $y = 'default') must be compatible with A::meow(string $x, string $y = 'default') in ...
I have seen other similar issues that involve abstract classes or interfaces, which is not the case here.
Why am I forced to define the exact same parameters?