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

Bug with parent word inside a namespace #3935

Closed
tristanbes opened this issue Jul 19, 2018 · 4 comments
Closed

Bug with parent word inside a namespace #3935

tristanbes opened this issue Jul 19, 2018 · 4 comments
Labels

Comments

@tristanbes
Copy link

tristanbes commented Jul 19, 2018

The PHP version you are using ($ php -v):

7.2.7

PHP CS Fixer version you are using ($ php-cs-fixer -V):

v2.12.2

The command you use to run PHP CS Fixer:

php-cs-fixer fix

The configuration file you are using, if any:

<?php

$finder = PhpCsFixer\Finder::create()
    ->in([__DIR__.'/src'])
    ->exclude(['Tests'])
;

return PhpCsFixer\Config::create()
    ->setRiskyAllowed(true)
    ->setRules([
        '@Symfony' => true,
        'no_unused_imports' => false,
        'array_syntax' => [
            'syntax' => 'short',
        ],
        'binary_operator_spaces' => [
            'align_double_arrow' => true,
            'align_equals' => true
        ],
        'no_unreachable_default_argument_value' => false,
        'braces' => [
            'allow_single_line_closure' => true,
        ],
        'heredoc_to_nowdoc' => false,
        'phpdoc_summary' => false,
        'yoda_style' => false,
        'native_constant_invocation' => true,
        'native_function_invocation' => [
            'include' => ['@compiler_optimized'],
            'scope'   => 'namespaced',
        ],
        'no_superfluous_phpdoc_tags' => true,
    ])
    ->setFinder($finder)
;

If applicable, please provide minimum samples of PHP code (as plain text, not screenshots):

  • before running PHP CS Fixer (no changes):
namespace Yprox\Model\Site\Parent;
  • with unexpected changes applied when running PHP CS Fixer:
namespace Yprox\Model\Site\parent;
  • with the changes you expected instead:
no changes
@keradus
Copy link
Member

keradus commented Jul 19, 2018

using semi-reserved words as namespace is not best idea imho :(

@kmvan
Copy link
Contributor

kmvan commented Jul 21, 2018

Why not rename the Parent namespace?

@kubawerlos
Copy link
Contributor

No matter if it's a good idea or bad it is a bug -> #3937

@ntzm
Copy link
Contributor

ntzm commented Oct 2, 2018

Can be closed now, is fixed as of 2.12.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants