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

[Finder] Only use GLOB_BRACE when available #14503

Closed
wants to merge 2 commits into from
Closed

[Finder] Only use GLOB_BRACE when available #14503

wants to merge 2 commits into from

Conversation

dosten
Copy link
Contributor

@dosten dosten commented Apr 29, 2015

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #14502
License MIT

@dosten
Copy link
Contributor Author

dosten commented Apr 29, 2015

The failing tests seems to be unrelated.

@stof
Copy link
Member

stof commented Apr 29, 2015

it would be better to avoid defining the constant if it is unsupported. It could break other tools checking the support for the feature by detecting the constant (we stopped redefining constants for ENT_SUBSTITUTE for this reason for instance, even though we may still have a few places using this pattern for other constants)

@dosten
Copy link
Contributor Author

dosten commented Apr 29, 2015

@webbird proposed this solution:
defined('GLOB_BRACE') ? GLOB_BRACE | GLOB_ONLYDIR : GLOB_ONLYDIR this is better?

@dosten
Copy link
Contributor Author

dosten commented Apr 29, 2015

btw, we override JSON_PRETTY_PRINT, this needs to be replaced in 2.6, 2.7 and 2.8? Ex:

  • Symfony/Bridge/Twig/Command/LintCommand
  • Symfony/Bundle/FrameworkBundle/Command/YamlLintCommand
  • Symfony/Bundle/FrameworkBundle/Console/Descriptor/JsonDescriptor
  • Symfony/Component/Translation/Dumper/JsonFileDumper

@dosten dosten changed the title [Finder] Define GLOB_BRACE if not exists [Finder] Only use GLOB_BRACE when available May 1, 2015
@dosten
Copy link
Contributor Author

dosten commented May 1, 2015

@stof i have updated the PR.

@stof
Copy link
Member

stof commented May 1, 2015

👍

@xabbuh xabbuh added the Finder label May 1, 2015
@xabbuh
Copy link
Member

xabbuh commented May 1, 2015

👍

@fabpot
Copy link
Member

fabpot commented May 1, 2015

Thank you @dosten.

fabpot added a commit that referenced this pull request May 1, 2015
This PR was squashed before being merged into the 2.6 branch (closes #14503).

Discussion
----------

[Finder] Only use GLOB_BRACE when available

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #14502
| License       | MIT

Commits
-------

7632d27 [Finder] Only use GLOB_BRACE when available
@fabpot fabpot closed this May 1, 2015
@dosten dosten deleted the issue-14502 branch May 1, 2015 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants