parser-reflection icon indicating copy to clipboard operation
parser-reflection copied to clipboard

Locator needs to be aware of prerequisite classes/interfaces/traits

Open loren-osborn opened this issue 7 years ago • 1 comments

I figured I might as well report this as well, as I already have a fix, and am just awaiting permission to issue a PR.

Go\ParserReflection\ReflectionClass fails to find parent classes, implemented interfaces and used traits defined in the same file prior to the referencing class/interface/trait unless the locator is aware of which file to each prerequisite. While this isn't the recommended way to organize classes, etc. the ReflectionEngine should be able to handle it as it's relatively common, (especially for "packaged" modules) and it's perfectly valid PHP without an autoloader.

As I said above, I'm hoping to issue a PR for this soon.

loren-osborn avatar Apr 09 '17 19:04 loren-osborn

This is a duplicate of issue #64, but I have a working fix for this that I just need permission to disclose and contribute.

loren-osborn avatar Apr 10 '17 16:04 loren-osborn