-
-
Notifications
You must be signed in to change notification settings - Fork 946
Closed
phpstan/phpstan-src
#231Description
Bug report
Memoization in MemoizingReflectionProvider lowercases the classname before using it as the cache key. If you reference the class with an incorrect case, and it fails to be autoloaded, the provider caches it as 'not found'. If it is then referenced with the correct casing the provider will not try to find it and report it as not found.
Code snippet that reproduces the problem
Assuming a case-sensitive autoloader that can find SomeClass but not someclass:
<?php
new someclass;
new SomeClass;
Output:
Instantiated class company not found.
Instantiated class Company not found.
Expected output
Instantiated class someclass not found.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels