Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] first draft to suggest requiring of extensions #9

Merged
merged 1 commit into from
Dec 16, 2015

Conversation

maglnet
Copy link
Owner

@maglnet maglnet commented Dec 4, 2015

As mentioned in #2, it would be nice to see, which dependency should be required to fix an unknown symbol.

This draft checks all loaded extensions for the unknown symbol and suggests requiring an extension if it can be found.

$loadedExtensions = get_loaded_extensions();

foreach ($loadedExtensions as $extensionName) {
$extensionSymbols = (new LocateDefinedSymbolsFromExtensions())->__invoke([$extensionName]);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can create this function outside the loop.

maglnet added a commit that referenced this pull request Dec 16, 2015
suggest dependencies depending on loaded extensions
@maglnet maglnet merged commit 4462c2d into master Dec 16, 2015
@maglnet maglnet deleted the feature/suggest-extensions branch December 16, 2015 13:41
MidnightDesign pushed a commit to MidnightDesign/ComposerRequireChecker that referenced this pull request Sep 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants