minor #30023 [Config] fix compat with wrapping autoloaders (nicolas-grekas)

This PR was merged into the 3.4 branch.

Discussion
----------

[Config] fix compat with wrapping autoloaders

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Registering this private method as autoloader works, until one wants to decorate autoloaders (like our DebugClassLoader does.)

Commits
-------

695d84be4c [Config] fix compat with wrapping autoloaders
This commit is contained in:
Nicolas Grekas 2019-01-30 12:33:42 +01:00
commit 82394d8a19
1 changed files with 3 additions and 1 deletions

View File

@ -118,8 +118,10 @@ class ClassExistenceResource implements SelfCheckingResourceInterface, \Serializ
/**
* @throws \ReflectionException When $class is not found and is required
*
* @internal
*/
private static function throwOnRequiredClass($class)
public static function throwOnRequiredClass($class)
{
if (self::$autoloadedClass === $class) {
return;