You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// PropertyNotSetInConstructor FooBarBaz::$valclass FooBarBaz extends BarBaz{
publicfunction__construct() { parent::__construct('val'); }
}
class BarBaz extends Baz
{
/** @var string */protected$val;
//private $val; // no issue foundpublicfunction__construct(string$val='')
{
$this->val = $val;
if (true)
parent::__construct();
// no issue found without if://parent::__construct();// no issue found without calling parent constructor at all
}
}
class Baz {
publicfunction__construct() { }
}
This seems to unexpectedly trigger PropertyNotSetInConstructor,
despite the property being set by the parent constructor.
The text was updated successfully, but these errors were encountered:
This seems to unexpectedly trigger PropertyNotSetInConstructor,
despite the property being set by the parent constructor.
The text was updated successfully, but these errors were encountered: