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

Feature: support reading from flysystem OR add method variants that take source as string

Open rulatir opened this issue 6 years ago • 2 comments

Please either support reading from flysystem, or add static method variants to ReflectionEngine that will take source code in a string instead of reading it from file.

(Also please use static:: instead of self:: everywhere).

rulatir avatar Oct 28 '19 02:10 rulatir

You could send a PR with static:: calls to this repo )

Also, you could use second parameter of ReflectionEngine::parseFile($fileName, $fileContent = null) to specify any arbitrary string content even for non-existent files.

lisachenko avatar Dec 04 '19 15:12 lisachenko

Back on the project after a long hiatus.

You could send a PR with static:: calls to this repo )

I'm considering.

Also, you could use second parameter of ReflectionEngine::parseFile($fileName, $fileContent = null) to specify any arbitrary string content even for non-existent files.

In order for this feature to be consistently usable, the support for this parameter would have to be added consistently to ALL methods that eventually pass control to ReflectionEngine::parseFile(), for example ReflectionEngine::parseFileNamespace(). Otherwise if I want the functionality of ReflectionEngine::parseFileNamespace() but with $fileContents, I must duplicate and modify the implementation of ReflectionEngine::parseFileNamespace().

rulatir avatar Jul 01 '20 10:07 rulatir