Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 43cf9e6

Browse filesBrowse files
minor #57476 Sync php-cs-fixer config file with 7.2 (nicolas-grekas)
This PR was merged into the 5.4 branch. Discussion ---------- Sync php-cs-fixer config file with 7.2 | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | no | New feature? | no | Deprecations? | no | Issues | - | License | MIT To help new PRs to have the CS expected on branch 7.2 Commits ------- 69e8b2f Sync php-cs-fixer config file with 7.2
2 parents e3af3f1 + 69e8b2f commit 43cf9e6
Copy full SHA for 43cf9e6

File tree

1 file changed

+11
-11
lines changed
Filter options

1 file changed

+11
-11
lines changed

‎.php-cs-fixer.dist.php

Copy file name to clipboardExpand all lines: .php-cs-fixer.dist.php
+11-11Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,11 @@
2929
'@Symfony' => true,
3030
'@Symfony:risky' => true,
3131
'protected_to_private' => false,
32-
'native_constant_invocation' => ['strict' => false],
33-
'nullable_type_declaration_for_default_null_value' => true,
3432
'header_comment' => ['header' => $fileHeaderComment],
33+
// TODO: Remove once the "compiler_optimized" set includes "sprintf"
34+
'native_function_invocation' => ['include' => ['@compiler_optimized', 'sprintf'], 'scope' => 'namespaced', 'strict' => true],
35+
'nullable_type_declaration' => true,
36+
'nullable_type_declaration_for_default_null_value' => true,
3537
])
3638
->setRiskyAllowed(true)
3739
->setFinder(
@@ -40,29 +42,27 @@
4042
->append([__FILE__])
4143
->notPath('#/Fixtures/#')
4244
->exclude([
43-
// directories containing files with content that is autogenerated by `var_export`, which breaks CS in output code
44-
// fixture templates
45-
'Symfony/Bundle/FrameworkBundle/Tests/Templating/Helper/Resources/Custom',
46-
// resource templates
47-
'Symfony/Bundle/FrameworkBundle/Resources/views/Form',
4845
// explicit trigger_error tests
4946
'Symfony/Bridge/PhpUnit/Tests/DeprecationErrorHandler/',
5047
'Symfony/Component/Intl/Resources/data/',
5148
])
49+
// explicit tests for ommited @param type, against `no_superfluous_phpdoc_tags`
50+
->notPath('Symfony/Component/PropertyInfo/Tests/Extractor/PhpDocExtractorTest.php')
51+
->notPath('Symfony/Component/PropertyInfo/Tests/Extractor/PhpStanExtractorTest.php')
5252
// Support for older PHPunit version
5353
->notPath('Symfony/Bridge/PhpUnit/SymfonyTestsListener.php')
5454
->notPath('#Symfony/Bridge/PhpUnit/.*Mock\.php#')
5555
->notPath('#Symfony/Bridge/PhpUnit/.*Legacy#')
5656
// file content autogenerated by `var_export`
5757
->notPath('Symfony/Component/Translation/Tests/fixtures/resources.php')
58-
// file content autogenerated by `VarExporter::export`
59-
->notPath('Symfony/Component/Serializer/Tests/Fixtures/serializer.class.metadata.php')
60-
// test template
61-
->notPath('Symfony/Bundle/FrameworkBundle/Tests/Templating/Helper/Resources/Custom/_name_entry_label.html.php')
6258
// explicit trigger_error tests
6359
->notPath('Symfony/Component/ErrorHandler/Tests/DebugClassLoaderTest.php')
6460
// stop removing spaces on the end of the line in strings
6561
->notPath('Symfony/Component/Messenger/Tests/Command/FailedMessagesShowCommandTest.php')
62+
// svg
63+
->notPath('Symfony/Component/ErrorHandler/Resources/assets/images/symfony-ghost.svg.php')
64+
// HTML templates
65+
->notPath('#Symfony/.*\.html\.php#')
6666
)
6767
->setCacheFile('.php-cs-fixer.cache')
6868
;

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.