-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Closed
Description
Q | A |
---|---|
Bug report? | no (unexpected behavior) |
Feature request? | yes |
BC Break report? | no |
RFC? | no |
Symfony version | 4.x |
While using the DIC component outside of the Symfony I found I need to define my own base_class
while calling PhpDumper::dump
in order to provide custom functionality. Compiled container indeed contains my class as a parent, however constructor of the class is not called. The generated constructor looks like that:
public function __construct()
{
$this->parameters = $this->getDefaultParameters();
$this->services = $this->privates = array();
$this->syntheticIds = array(
//...
);
$this->methodMap = array(
//...
);
$this->aliases = array(
//...
);
}
I checked and this behavior is consistent across 4.0, 3.4 and 3.3 with or without as_files
enabled. I guess then the decision was deliberate.
Is there any reason why not to call the base container constructor? WDYT about adding such option?