wp-includes/php-ai-client/third-party/Http/Discovery/ClassDiscovery.php:186Get an instance of the $class.
$classstring|Closureobject protected static function instantiateClass($class) { try { if (is_string($class)) { return new $class(); } if (is_callable($class)) { return $class(); } } catch (\Exception $e) { throw new ClassInstantiationFailedException('Unexpected exception when instantiating class.', 0, $e); } throw new ClassInstantiationFailedException('Could not instantiate class because parameter is neither a callable nor a string'); }Unchanged from 7.0.4 through 7.1.0.
Signature, return type and hooks compared across 2 parsed releases.
src/wp-includes/php-ai-client/third-party/Http/Discovery/ClassDiscovery.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.