wp-includes/SimplePie/src/Registry.php:186Create a new instance of a given type
$typeSimplePie\class-string<T>$parametersSimplePie\array<mixed>optional[]SimplePie\T public function &create($type, array $parameters = []) { $class = $this->get_class($type); if ($class === null) { throw new InvalidArgumentException(sprintf( '%s(): Argument #1 ($type) "%s" not found in class list.', __METHOD__, $type ), 1); } if (!method_exists($class, '__construct')) { $instance = new $class(); } else { $reflector = new \ReflectionClass($class); // For PHPStan: $class is T. /** @var T */ $instance = $reflector->newInstanceArgs($parameters); } if ($instance instanceof RegistryAware) { $instance->set_registry($this); } elseif (method_exists($instance, 'set_registry')) { trigger_error(sprintf('Using the method "set_registry()" without implementing "%s" is deprecated since SimplePie 1.8.0, implement "%s" in "%s".', RegistryAware::class, RegistryAware::class, $class), \E_USER_DEPRECATED); $instance->set_registry($this); } return $instance; }One change between 6.7.7 and 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
$parameters retyped from array to SimplePie\array<mixed>.verified against sourcesrc/wp-includes/SimplePie/src/Registry.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.