symfony/symfony — Issue #2730: Service definition without any parameters create call to getDefaultParameters without implementation
Author: ambis
Created: 2011-11-27 00:11:21+00:00
State: open

I have an XML definition of my services (not an SF2 app, only the DIC is in use ATM).

While there are no parameters in the services definition, the PhpDumper creates a constructor such as this:

parent::__construct(new ParameterBag($this->getDefaultParameters()));

But it does not create the 'getDefaultParameters' method implementation if there are no parameters. By just adding a foo=bar parameter the method will be implemented. See the addDefaultParametersMethod() method in the PhpDumper.

I'm at commit 1a5e0acd02.