├── .travis.yml ├── CONTRIBUTING.md ├── CONTRIBUTORS.md ├── COOKBOOK.md ├── ISSUE_TEMPLATE.md ├── LICENSE ├── README.md ├── aphpfmt ├── composer.json ├── composer.phar ├── fmt.phar ├── fmt.phar.sha1 ├── fmt.php ├── phpstorm-configuration.png └── src ├── .phpfmt.ini ├── AddLicense.php ├── Additionals ├── AddMissingParentheses.php ├── AdditionalPass.php ├── AliasToMaster.php ├── AlignConstVisibilityEquals.php ├── AlignDoubleArrow.php ├── AlignDoubleSlashComments.php ├── AlignEquals.php ├── AlignGroupDoubleArrow.php ├── AlignPHPCode.php ├── AlignTypehint.php ├── AllmanStyleBraces.php ├── AutoPreincrement.php ├── AutoSemicolon.php ├── CakePHPStyle.php ├── ClassToSelf.php ├── ClassToStatic.php ├── ConvertOpenTagWithEcho.php ├── DocBlockToComment.php ├── DoubleToSingleQuote.php ├── EchoToPrint.php ├── EncapsulateNamespaces.php ├── GeneratePHPDoc.php ├── IndentTernaryConditions.php ├── JoinToImplode.php ├── LeftWordWrap.php ├── LongArray.php ├── MergeElseIf.php ├── MergeNamespaceWithOpenTag.php ├── MildAutoPreincrement.php ├── NewLineBeforeReturn.php ├── NoSpaceAfterPHPDocBlocks.php ├── OnlyOrderUseClauses.php ├── OrderAndRemoveUseClauses.php ├── OrderMethod.php ├── OrderMethodAndVisibility.php ├── OrganizeClass.php ├── PHPDocTypesToFunctionTypehint.php ├── PSR2EmptyFunction.php ├── PSR2MultilineFunctionParams.php ├── PrettyPrintDocBlocks.php ├── ReindentAndAlignObjOps.php ├── ReindentSwitchBlocks.php ├── RemoveIncludeParentheses.php ├── RemoveSemicolonAfterCurly.php ├── RemoveUseLeadingSlash.php ├── ReplaceBooleanAndOr.php ├── ReplaceIsNull.php ├── RestoreComments.php ├── ReturnNull.php ├── ShortArray.php ├── SmartLnAfterCurlyOpen.php ├── SortUseNameSpace.php ├── SpaceAfterExclamationMark.php ├── SpaceAroundControlStructures.php ├── SpaceAroundExclamationMark.php ├── SpaceBetweenMethods.php ├── SplitElseIf.php ├── StrictBehavior.php ├── StrictComparison.php ├── StripExtraCommaInArray.php ├── StripNewlineAfterClassOpen.php ├── StripNewlineAfterCurlyOpen.php ├── StripNewlineWithinClassBody.php ├── StripSpaceWithinControlStructures.php ├── StripSpaces.php ├── TightConcat.php ├── TrimSpaceBeforeSemicolon.php ├── UpgradeToPreg.php ├── WordWrap.php ├── WrongConstructorName.php └── YodaComparisons.php ├── Core ├── AddMissingCurlyBraces.php ├── AutoImport.php ├── BaseCodeFormatter.php ├── Cache.php ├── CacheDummy.php ├── Cacher.php ├── CodeFormatter.php ├── CodeFormatter_debug.php ├── CodeFormatter_profile.php ├── ConstructorPass.php ├── EliminateDuplicatedEmptyLines.php ├── ExtraCommaInArray.php ├── FormatterPass.php ├── LeftAlignComment.php ├── MergeCurlyCloseAndDoWhile.php ├── MergeDoubleArrowAndArray.php ├── MergeParenCloseWithCurlyOpen.php ├── NormalizeIsNotEquals.php ├── NormalizeLnAndLtrimLines.php ├── RTrim.php ├── Reindent.php ├── ReindentColonBlocks.php ├── ReindentComments.php ├── ReindentEqual.php ├── ReindentObjOps.php ├── ResizeSpaces.php ├── SettersAndGettersPass.php ├── SingleCodeFormatter.php ├── SplitCurlyCloseAndTokens.php ├── StripExtraCommaInList.php ├── SurrogateToken.php ├── Tree.php ├── TwoCommandsInSameLine.php └── constants.php ├── PSR ├── PSR1BOMMark.php ├── PSR1ClassConstants.php ├── PSR1ClassNames.php ├── PSR1MethodNames.php ├── PSR1OpenTags.php ├── PSR2AlignObjOp.php ├── PSR2CurlyOpenNextLine.php ├── PSR2IndentWithSpace.php ├── PSR2KeywordsLowerCase.php ├── PSR2LnAfterNamespace.php ├── PSR2ModifierVisibilityStaticOrder.php ├── PSR2SingleEmptyLineAndStripClosingTag.php └── PsrDecorator.php ├── bench.go ├── build.php ├── cli-core.php ├── composer.json ├── fmt-external.src.php ├── fmt-external.stub.src.php ├── fmt.src.php ├── fmt.stub.src.php ├── helpers.php ├── selfupdate.php ├── test.php ├── tests-PSR ├── 001-short-open-tag.in ├── 001-short-open-tag.out ├── 002-BOM.in ├── 002-BOM.out ├── 003-ClassName.in ├── 003-ClassName.out ├── 004-last-empty-line.in ├── 004-last-empty-line.out ├── 005-lower-case-keywords.in ├── 005-lower-case-keywords.out ├── 006-wrong-visibility.in ├── 006-wrong-visibility.out ├── 007-BUG-PSR2ModifierVisibilityStaticOrder.in ├── 007-BUG-PSR2ModifierVisibilityStaticOrder.out ├── 008-wrong-curly-for-traits-interfaces.in ├── 008-wrong-curly-for-traits-interfaces.out ├── 009-bug-use-autosort-and-traits.in ├── 009-bug-use-autosort-and-traits.out ├── 010-wrong-lower-case.in ├── 010-wrong-lower-case.out ├── 011-wrong-name-change.in ├── 011-wrong-name-change.out ├── 012-vanishing-static.in ├── 012-vanishing-static.out ├── 013-Multi-line-function-definition.in ├── 013-Multi-line-function-definition.out ├── 014-bug-22.in ├── 014-bug-22.out ├── 015-bug-35.in ├── 015-bug-35.out ├── 016-bug-42.in ├── 016-bug-42.out ├── 017-ln-before-namespace.in ├── 017-ln-before-namespace.out ├── 018-visibility-modifier.in ├── 018-visibility-modifier.out ├── 019-broken-align.in ├── 019-broken-align.out ├── 020-broken-align-objop.in ├── 020-broken-align-objop.out ├── 021-wrong-spacing-at-comment.in ├── 021-wrong-spacing-at-comment.out ├── 022-sublime-phpfmt-58.in ├── 022-sublime-phpfmt-58.out ├── 023-sublime-phpfmt-58.in ├── 023-sublime-phpfmt-58.out ├── 024-sublime-phpfmt-58.in ├── 024-sublime-phpfmt-58.out ├── 025-lowercase-constants.in ├── 025-lowercase-constants.out ├── 026-lowercase-constants-with-comments.in ├── 026-lowercase-constants-with-comments.out ├── 027-wrong-visibility.in ├── 027-wrong-visibility.out ├── 028-method-name-propagation.in ├── 028-method-name-propagation.out ├── 029-lower-case.in ├── 029-lower-case.out ├── 030-dirty-heredoc.in ├── 030-dirty-heredoc.out ├── 031-visibility-coverage.in ├── 031-visibility-coverage.out ├── 032-visibility-with-reference.in ├── 032-visibility-with-reference.out ├── 033-wrong-lowercase.in ├── 033-wrong-lowercase.out ├── 034-invalid-close-tag-removal.in ├── 034-invalid-close-tag-removal.out ├── 035-concat-method-with-heredoc.in ├── 035-concat-method-with-heredoc.out ├── 036-wrong-lowercase.in ├── 036-wrong-lowercase.out ├── 037-empty-function.in ├── 037-empty-function.out ├── 038-t-var.in ├── 038-t-var.out ├── 039-wrong-brace-placement.in ├── 039-wrong-brace-placement.out ├── 040-wrong-visibility-handling.in ├── 040-wrong-visibility-handling.out ├── 041-bug.in ├── 041-bug.out ├── 042-coverage-visibility-order.in ├── 042-coverage-visibility-order.out ├── 043-short-open-tags.in ├── 043-short-open-tags.out ├── 044-short-open-tags.in ├── 044-short-open-tags.out ├── 045-auto-semicolon.in ├── 045-auto-semicolon.out ├── 046-switch.in ├── 046-switch.out ├── 047-short-open-tags.in ├── 047-short-open-tags.out ├── 048-reindent-source.in ├── 048-reindent-source.out ├── 049-bug-visibility-order.in ├── 049-bug-visibility-order.out ├── 050-space-within-class.in ├── 050-space-within-class.out ├── 051-space-within-class.in ├── 051-space-within-class.out ├── 052-name-change.in └── 052-name-change.out ├── tests ├── 000-break_line.in ├── 000-break_line.out ├── 001-if.in ├── 001-if.out ├── 002-switch.in ├── 002-switch.out ├── 003-namespace_and_uses.in ├── 003-namespace_and_uses.out ├── 004-align_vars.in ├── 004-align_vars.out ├── 005-BUGFIX_array_dereference_from_object.in ├── 005-BUGFIX_array_dereference_from_object.out ├── 006-BUGFIX_heredoc.in ├── 006-BUGFIX_heredoc.out ├── 007-uses.in ├── 007-uses.out ├── 008-array_multiline.in ├── 008-array_multiline.out ├── 009-while_while.in ├── 009-while_while.out ├── 010-BUGFIX_deference_in_mixed_array.in ├── 010-BUGFIX_deference_in_mixed_array.out ├── 011-BUGFIX_else_colon.in ├── 011-BUGFIX_else_colon.out ├── 012-BUGFIX_remark_between_parentheses_and_obj_accessor.in ├── 012-BUGFIX_remark_between_parentheses_and_obj_accessor.out ├── 013-BUGFIX_remark_between_parentheses_and_curly.in ├── 013-BUGFIX_remark_between_parentheses_and_curly.out ├── 014-BUGFIX_comment_within_array.in ├── 014-BUGFIX_comment_within_array.out ├── 015-BUGFIX_comment_breaking_syntax.in ├── 015-BUGFIX_comment_breaking_syntax.out ├── 016-BUGFIX_broken_auto_curly.in ├── 016-BUGFIX_broken_auto_curly.out ├── 017-BUGFIX_broken_auto_curly_2.in ├── 017-BUGFIX_broken_auto_curly_2.out ├── 018-BUGFIX_broken_auto_curly_3.in ├── 018-BUGFIX_broken_auto_curly_3.out ├── 019-short_array_multiline.in ├── 019-short_array_multiline.out ├── 020-BUGFIX_comment_within_array.in ├── 020-BUGFIX_comment_within_array.out ├── 021-BUGFIX_misinteraction_between_param_and_array.in ├── 021-BUGFIX_misinteraction_between_param_and_array.out ├── 022-BUGFIX_misinteraction_between_param_and_array.in ├── 022-BUGFIX_misinteraction_between_param_and_array.out ├── 023-BUGFIX_broken_auto_curly_4.in ├── 023-BUGFIX_broken_auto_curly_4.out ├── 024-booleans.in ├── 024-booleans.out ├── 025-comment_breaking_syntax.in ├── 025-comment_breaking_syntax.out ├── 026-broken-indent.in ├── 026-broken-indent.out ├── 027-comments_breaking_syntax.in ├── 027-comments_breaking_syntax.out ├── 028-wrong_artificial_curly.in ├── 028-wrong_artificial_curly.out ├── 029-comment_breaking_syntax_comma.in ├── 029-comment_breaking_syntax_comma.out ├── 030-broken_indentation_2.in ├── 030-broken_indentation_2.out ├── 031-artificial_curly_wrongly_emitted.in ├── 031-artificial_curly_wrongly_emitted.out ├── 032-traits.in ├── 032-traits.out ├── 033-wrongly_emitted_artificial_curly.in ├── 033-wrongly_emitted_artificial_curly.out ├── 034-comments_breaking_syntax.in ├── 034-comments_breaking_syntax.out ├── 035-multibreak.in ├── 035-multibreak.out ├── 036-break-deep.in ├── 036-break-deep.out ├── 037-preserve-blank-lines.in ├── 037-preserve-blank-lines.out ├── 038-broken-array-ln.in ├── 038-broken-array-ln.out ├── 039-broken-mix-short-long-arrays.in ├── 039-broken-mix-short-long-arrays.out ├── 040-broken-alignment.in ├── 040-broken-alignment.out ├── 041-broken-else-elseif.in ├── 041-broken-else-elseif.out ├── 042-align_vars.in ├── 042-align_vars.out ├── 043-clever-array.in ├── 043-clever-array.out ├── 044-space-between-functions.in ├── 044-space-between-functions.out ├── 045-remark-after-constant.in ├── 045-remark-after-constant.out ├── 046-preserve-object-operator-indentation.in ├── 046-preserve-object-operator-indentation.out ├── 047-space-after-curly-braces.in ├── 047-space-after-curly-braces.out ├── 048-space-before-doc-comment.in ├── 048-space-before-doc-comment.out ├── 049-align-comments.in ├── 049-align-comments.out ├── 050-comment-not-in-next-line.in ├── 050-comment-not-in-next-line.out ├── 051-wrong-line-merge.in ├── 051-wrong-line-merge.out ├── 052-wrong-line-deletion-between-attr-and-if.in ├── 052-wrong-line-deletion-between-attr-and-if.out ├── 053-wrong-alignment.in ├── 053-wrong-alignment.out ├── 054-wrong-line-break-merge.in ├── 054-wrong-line-break-merge.out ├── 055-wrong-alignment-within-comment.in ├── 055-wrong-alignment-within-comment.out ├── 056-wrong-extra-line.in ├── 056-wrong-extra-line.out ├── 057-comment-and-semicolon.in ├── 057-comment-and-semicolon.out ├── 058-keep-ln-after-comma-and-paren.in ├── 058-keep-ln-after-comma-and-paren.out ├── 059-wrong-space-in-type-hint.in ├── 059-wrong-space-in-type-hint.out ├── 060-wrong-line-merge-after-comment.in ├── 060-wrong-line-merge-after-comment.out ├── 061-keep-ln-after-comma-and-paren.in ├── 061-keep-ln-after-comma-and-paren.out ├── 062-double-colon.in ├── 062-double-colon.out ├── 063-two-commands-same-line.in ├── 063-two-commands-same-line.out ├── 064-wrong-comment-indentation.in ├── 064-wrong-comment-indentation.out ├── 065-wrong-line-merge.in ├── 065-wrong-line-merge.out ├── 066-double-arrow.in ├── 066-double-arrow.out ├── 067-else-plus-if.in ├── 067-else-plus-if.out ├── 068-extra-comma-in-array.in ├── 068-extra-comma-in-array.out ├── 069-var-in-string.in ├── 069-var-in-string.out ├── 070-obj-op-indent.in ├── 070-obj-op-indent.out ├── 071-wrong-objop-align.in ├── 071-wrong-objop-align.out ├── 072-wrong-objop-short-array.in ├── 072-wrong-objop-short-array.out ├── 073-wrong-extra-comma.in ├── 073-wrong-extra-comma.out ├── 074-wrong-align-in-str.in ├── 074-wrong-align-in-str.out ├── 075-empty-lines.in ├── 075-empty-lines.out ├── 076-wrong-extra-comma-in-array.in ├── 076-wrong-extra-comma-in-array.out ├── 077-BUG-concat.in ├── 077-BUG-concat.out ├── 078-wrong-alignment-with-deeper-indent.in ├── 078-wrong-alignment-with-deeper-indent.out ├── 079-colon-blocks.in ├── 079-colon-blocks.out ├── 080-comments-indent.in ├── 080-comments-indent.out ├── 081-double-arrow-misalign.in ├── 081-double-arrow-misalign.out ├── 082-wrong-linebreak-after-public.in ├── 082-wrong-linebreak-after-public.out ├── 083-wrong-equal-alignment.in ├── 083-wrong-equal-alignment.out ├── 084-double-arrow-misalign.in ├── 084-double-arrow-misalign.out ├── 085-uses-not-removing-empty-line.in ├── 085-uses-not-removing-empty-line.out ├── 086-indent-bug.in ├── 086-indent-bug.out ├── 087-arithmetic-spacing.in ├── 087-arithmetic-spacing.out ├── 088-chain-effect.in ├── 088-chain-effect.out ├── 089-aired-out-spacing-bug.in ├── 089-aired-out-spacing-bug.out ├── 090-continue-spacing.in ├── 090-continue-spacing.out ├── 091-spacing-array-cast.in ├── 091-spacing-array-cast.out ├── 092-spacing-docblock-class.in ├── 092-spacing-docblock-class.out ├── 093-wrong-spacing-reference.in ├── 093-wrong-spacing-reference.out ├── 094-wrong-indentation.in ├── 094-wrong-indentation.out ├── 095-wrong-implicit-indentation.in ├── 095-wrong-implicit-indentation.out ├── 096-use-clause-within-docblocks.in ├── 096-use-clause-within-docblocks.out ├── 097-two-whiles.in ├── 097-two-whiles.out ├── 098-wrong-while-position.in ├── 098-wrong-while-position.out ├── 099-wrong-while-position-II.in ├── 099-wrong-while-position-II.out ├── 100-array-heredoc.in ├── 100-array-heredoc.out ├── 101-bug-22.in ├── 101-bug-22.out ├── 102-two-commands-same-line.in ├── 102-two-commands-same-line.out ├── 103-bug-614.in ├── 103-bug-614.out ├── 104-bug-37.in ├── 104-bug-37.out ├── 105-space-between-use-clauses.in ├── 105-space-between-use-clauses.out ├── 106-decrement-spacing-issue.in ├── 106-decrement-spacing-issue.out ├── 107-proposal-for-40.in ├── 107-proposal-for-40.out ├── 108-indentation-bug.in ├── 108-indentation-bug.out ├── 109-spacing-bug.in ├── 109-spacing-bug.out ├── 110-st-reference-space-bug.in ├── 110-st-reference-space-bug.out ├── 111-bug-add-curly-brace.in ├── 111-bug-add-curly-brace.out ├── 112-short-ternary-op.in ├── 112-short-ternary-op.out ├── 113-bug-add-curly-brace-smart.in ├── 113-bug-add-curly-brace-smart.out ├── 114-crazy-braces.in ├── 114-crazy-braces.out ├── 115-yoda-comparison.in ├── 115-yoda-comparison.out ├── 116-pre-increment.in ├── 116-pre-increment.out ├── 117-multiple-namespaces.in ├── 117-multiple-namespaces.out ├── 118-bug-PR-10.in ├── 118-bug-PR-10.out ├── 119-bug-PR-10.in ├── 119-bug-PR-10.out ├── 120-t-print.in ├── 120-t-print.out ├── 121-heredoc-semi-colon.in ├── 121-heredoc-semi-colon.out ├── 122-spacing-bug.in ├── 122-spacing-bug.out ├── 123-amazon-bug.in ├── 123-amazon-bug.out ├── 124-wrong-curly-in-string.in ├── 124-wrong-curly-in-string.out ├── 125-variadics.in ├── 125-variadics.out ├── 126-class-FQN.in ├── 126-class-FQN.out ├── 127-optional-passes.in ├── 127-optional-passes.out ├── 128-merge-else-if.in ├── 128-merge-else-if.out ├── 129-short-array.in ├── 129-short-array.out ├── 130-spacing-coverage.in ├── 130-spacing-coverage.out ├── 131-smart-curly-coverage.in ├── 131-smart-curly-coverage.out ├── 132-order-use-clauses-coverage.in ├── 132-order-use-clauses-coverage.out ├── 133-order-use-clauses-coverage.in ├── 133-order-use-clauses-coverage.out ├── 134-reindent-loop-coverage.in ├── 134-reindent-loop-coverage.out ├── 135-setters-getters-camel-case.in ├── 135-setters-getters-camel-case.out ├── 136-setters-getters-snake-case.in ├── 136-setters-getters-snake-case.out ├── 137-setters-getters-go-case.in ├── 137-setters-getters-go-case.out ├── 138-setters-getters-default-case.in ├── 138-setters-getters-default-case.out ├── 140-try-catch-finally.in ├── 140-try-catch-finally.out ├── 141-short-array.in ├── 141-short-array.out ├── 142-declare-spacing.in ├── 142-declare-spacing.out ├── 143-remove-leading-slash.in ├── 143-remove-leading-slash.out ├── 144-broken-align.in ├── 144-broken-align.out ├── 145-traits-conflict-resolution.in ├── 145-traits-conflict-resolution.out ├── 146-remove-leading-slash-expanded.in ├── 146-remove-leading-slash-expanded.out ├── 147-wrong-use-removal.in ├── 147-wrong-use-removal.out ├── 148-remove-leading-slash-expanded.in ├── 148-remove-leading-slash-expanded.out ├── 149-merge-lines.in ├── 149-merge-lines.out ├── 150-merge-line-properties.in ├── 150-merge-line-properties.out ├── 151-include-normalization.in ├── 151-include-normalization.out ├── 152-space-within-type-cast.in ├── 152-space-within-type-cast.out ├── 153-normalize-is-not-equals.in ├── 153-normalize-is-not-equals.out ├── 154-remove-leading-slash-no-namespace.in ├── 154-remove-leading-slash-no-namespace.out ├── 155-broken-code.in ├── 155-broken-code.out ├── 156-phpdoc-generator.in ├── 156-phpdoc-generator.out ├── 157-auto-align-error.in ├── 157-auto-align-error.out ├── 158-space-between-methods.in ├── 158-space-between-methods.out ├── 159-repeated-colon.in ├── 159-repeated-colon.out ├── 160-extra-comma-in-array.in ├── 160-extra-comma-in-array.out ├── 161-return-null.in ├── 161-return-null.out ├── 162-space-between-methods-bug.in ├── 162-space-between-methods-bug.out ├── 163-wrong-align.in ├── 163-wrong-align.out ├── 164-wrong-align-objop.in ├── 164-wrong-align-objop.out ├── 165-add-missing-parentheses.in ├── 165-add-missing-parentheses.out ├── 166-auto-align-error-take-II.in ├── 166-auto-align-error-take-II.out ├── 167-auto-align-error-take-III.in ├── 167-auto-align-error-take-III.out ├── 168-multi-line-array.in ├── 168-multi-line-array.out ├── 169-wrong-align.in ├── 169-wrong-align.out ├── 170-multi-line-array-more-cases.in ├── 170-multi-line-array-more-cases.out ├── 171-wrong-align.in ├── 171-wrong-align.out ├── 172-wrong-constructor-name.in ├── 172-wrong-constructor-name.out ├── 173-wrong-constructor-name.in ├── 173-wrong-constructor-name.out ├── 174-phpdoc-generator.in ├── 174-phpdoc-generator.out ├── 175-join-to-implode.in ├── 175-join-to-implode.out ├── 176-wrong-comment-indendation.in ├── 176-wrong-comment-indendation.out ├── 177-bug-sublime-77.in ├── 177-bug-sublime-77.out ├── 178-bug-sublime-77.in ├── 178-bug-sublime-77.out ├── 179-join-to-implode.in ├── 179-join-to-implode.out ├── 180-encapsulate-namespaces.in ├── 180-encapsulate-namespaces.out ├── 181-encapsulate-namespaces.in ├── 181-encapsulate-namespaces.out ├── 182-extra-comma-in-array-bug.in ├── 182-extra-comma-in-array-bug.out ├── 183-phpdoc-generator-coverage.in ├── 183-phpdoc-generator-coverage.out ├── 184-order-method-case-coverage.in ├── 184-order-method-case-coverage.out ├── 185-remove-include-parentheses-coverage.in ├── 185-remove-include-parentheses-coverage.out ├── 186-wrong-merge.in ├── 186-wrong-merge.out ├── 187-encapsulate-namespaces-inline-html.in ├── 187-encapsulate-namespaces-inline-html.out ├── 188-comment-within-if-and-switch.in ├── 188-comment-within-if-and-switch.out ├── 190-tight-concat.in ├── 190-tight-concat.out ├── 191-cakephp-style.in ├── 191-cakephp-style.out ├── 192-callable-typehint.in ├── 192-callable-typehint.out ├── 193-dynamic-vars.in ├── 193-dynamic-vars.out ├── 194-wrong-objop-indent.in ├── 194-wrong-objop-indent.out ├── 195-several-spacing-issues.in ├── 195-several-spacing-issues.out ├── 196-regression-align-objop.in ├── 196-regression-align-objop.out ├── 197-encapsulate-namespaces-close-tag.in ├── 197-encapsulate-namespaces-close-tag.out ├── 198-resize-spaces-coverage.in ├── 198-resize-spaces-coverage.out ├── 199-ident-with-space-special-size.in ├── 199-ident-with-space-special-size.out ├── 200-wrong-visibility.in ├── 200-wrong-visibility.out ├── 201-BUGFIX_heredoc_wrong_alignment.in ├── 201-BUGFIX_heredoc_wrong_alignment.out ├── 202-wrong-objop-align.in ├── 202-wrong-objop-align.out ├── 203-wrong-objop-align.in ├── 203-wrong-objop-align.out ├── 204-wrong-alignment.in ├── 204-wrong-alignment.out ├── 205-wrong-comment-indentation.in ├── 205-wrong-comment-indentation.out ├── 206-wrong-paren-count-reindent-objop.in ├── 206-wrong-paren-count-reindent-objop.out ├── 207-wrong-reindent-obj-count.in ├── 207-wrong-reindent-obj-count.out ├── 208-objop-reindent-two-obj.in ├── 208-objop-reindent-two-obj.out ├── 209-join-to-implode.in ├── 209-join-to-implode.out ├── 210-missing-semi-colon-and-curly-block.in ├── 210-missing-semi-colon-and-curly-block.out ├── 211-spacing-semicolon-comments.in ├── 211-spacing-semicolon-comments.out ├── 212-missing-semi-colon-and-curly-block.in ├── 212-missing-semi-colon-and-curly-block.out ├── 213-negative-candidates.in ├── 213-negative-candidates.out ├── 214-reindentobjop-coverage.in ├── 214-reindentobjop-coverage.out ├── 215-missing-semi-colon-and-curly-block-coverage.in ├── 215-missing-semi-colon-and-curly-block-coverage.out ├── 216-missing-semi-colon-and-curly-block-coverage.in ├── 216-missing-semi-colon-and-curly-block-coverage.out ├── 217-wrong-new-line.in ├── 217-wrong-new-line.out ├── 218-mild-pre-increment.in ├── 218-mild-pre-increment.out ├── 219-st_reference_spacing.in ├── 219-st_reference_spacing.out ├── 220-spacing-operators.in ├── 220-spacing-operators.out ├── 221-cakephp-style.in ├── 221-cakephp-style.out ├── 222-cakephp-style-casts.in ├── 222-cakephp-style-casts.out ├── 223-wrong-spacing-tcurly.in ├── 223-wrong-spacing-tcurly.out ├── 224-spacing-issues.in ├── 224-spacing-issues.out ├── 225-cakephp-style-references.in ├── 225-cakephp-style-references.out ├── 226-spacing-issue-doublearrow.in ├── 226-spacing-issue-doublearrow.out ├── 227-missing-visibility.in ├── 227-missing-visibility.out ├── 228-cakephp-coverage.in ├── 228-cakephp-coverage.out ├── 229-cakephp-underscore-normalization.in ├── 229-cakephp-underscore-normalization.out ├── 230-cakephp-underscore-normalization.in ├── 230-cakephp-underscore-normalization.out ├── 231-wrong-space-variable-variables.in ├── 231-wrong-space-variable-variables.out ├── 232-wrong-space-variable-variables.in ├── 232-wrong-space-variable-variables.out ├── 233-wrong-ln.in ├── 233-wrong-ln.out ├── 234-chinese.in ├── 234-chinese.out ├── 235-reindent-dollar-curly.in ├── 235-reindent-dollar-curly.out ├── 236-pre-increment-complex-vars.in ├── 236-pre-increment-complex-vars.out ├── 237-no-space-after-docblocks.in ├── 237-no-space-after-docblocks.out ├── 238-wrong-reindentobjop.in ├── 238-wrong-reindentobjop.out ├── 239-merge-open-with-namespace.in ├── 239-merge-open-with-namespace.out ├── 240-negative-candidates.in ├── 240-negative-candidates.out ├── 241-extra-comma-in-array.in ├── 241-extra-comma-in-array.out ├── 242-strip-extra-comma-in-array.in ├── 242-strip-extra-comma-in-array.out ├── 243-bug-sublime-71.in ├── 243-bug-sublime-71.out ├── 244-bug-sublime-72.in ├── 244-bug-sublime-72.out ├── 245-strip-ln-after-class-curly-open.in ├── 245-strip-ln-after-class-curly-open.out ├── 246-strip-ln-after-curly-open.in ├── 246-strip-ln-after-curly-open.out ├── 247-missing-semi-colon-and-curly-block-coverage.in ├── 247-missing-semi-colon-and-curly-block-coverage.out ├── 248-fix-bug-include-parentheses-removal.in ├── 248-fix-bug-include-parentheses-removal.out ├── 249-improving-setter-getter-generator.in ├── 249-improving-setter-getter-generator.out ├── 250-pretty-print-docblocks.in ├── 250-pretty-print-docblocks.out ├── 251-pretty-print-docblocks.in ├── 251-pretty-print-docblocks.out ├── 252-pretty-print-docblocks.in ├── 252-pretty-print-docblocks.out ├── 253-doc-block-beautifier.in ├── 253-doc-block-beautifier.out ├── 255-function-return-reference.in ├── 255-function-return-reference.out ├── 256-spacing-parentheses-comment.in ├── 256-spacing-parentheses-comment.out ├── 257-broken-add-missing-curly-braces.in ├── 257-broken-add-missing-curly-braces.out ├── 259-extra-alignments-alignment.in ├── 259-extra-alignments-alignment.out ├── 260-extra-alignments-typecast.in ├── 260-extra-alignments-typecast.out ├── 261-phpdoc-beautifer.in ├── 261-phpdoc-beautifer.out ├── 262-missing-curly-coverage.in ├── 262-missing-curly-coverage.out ├── 263-typehint-coverage.in ├── 263-typehint-coverage.out ├── 267-wrong-html.in ├── 267-wrong-html.out ├── 268-long-array.in ├── 268-long-array.out ├── 269-strict-comparison.in ├── 269-strict-comparison.out ├── 270-strict-funcs-params.in ├── 270-strict-funcs-params.out ├── 271-improving-short-array-detection.in ├── 271-improving-short-array-detection.out ├── 272-wordwrap.in ├── 272-wordwrap.out ├── 273-wordwrap.in ├── 273-wordwrap.out ├── 274-align-comments-in-function.in ├── 274-align-comments-in-function.out ├── 275-spacing-in-function-call.in ├── 275-spacing-in-function-call.out ├── 276-docblock-to-comment.in ├── 276-docblock-to-comment.out ├── 277-upgrade-to-preg.in ├── 277-upgrade-to-preg.out ├── 279-issue88-objop-align.in ├── 279-issue88-objop-align.out ├── 280-bitwise-ops.in ├── 280-bitwise-ops.out ├── 281-fix-missing-curly-braces.in ├── 281-fix-missing-curly-braces.out ├── 282-try-catch-missing-curly-braces.in ├── 282-try-catch-missing-curly-braces.out ├── 283-wrong-missing-curly-braces.in ├── 283-wrong-missing-curly-braces.out ├── 284-missing-parentheses.in ├── 284-missing-parentheses.out ├── 285-strip-last-comma-in-list.in ├── 285-strip-last-comma-in-list.out ├── 286-wrong-setter-getter-default-value.in ├── 286-wrong-setter-getter-default-value.out ├── 287-indent-ternary.in ├── 287-indent-ternary.out ├── 288-replace-is-null.in ├── 288-replace-is-null.out ├── 289-test-align-objop.in ├── 289-test-align-objop.out ├── 290-issue-101.in ├── 290-issue-101.out ├── 291-issue-101.in ├── 291-issue-101.out ├── 292-extra-comma-in-array-bug.in ├── 292-extra-comma-in-array-bug.out ├── 293-namespaces-vs-namespace-named-ns.in ├── 293-namespaces-vs-namespace-named-ns.out ├── 294-t-spaceship.in ├── 294-t-spaceship.out ├── 295-double-to-single-quotes.in ├── 295-double-to-single-quotes.out ├── 296-double-to-single-quotes-fix.in ├── 296-double-to-single-quotes-fix.out ├── 297-wrong-docblock-tidy.in ├── 297-wrong-docblock-tidy.out ├── 298-indent-ternary-with-spaces.in ├── 298-indent-ternary-with-spaces.out ├── 299-wrong-objop-indent.in ├── 299-wrong-objop-indent.out ├── 300-scalar-hint-and-return-types.in ├── 300-scalar-hint-and-return-types.out ├── 301-open-tag-with-echo.in ├── 301-open-tag-with-echo.out ├── 302-alias-to-master.in ├── 302-alias-to-master.out ├── 303-lwordwrap.in ├── 303-lwordwrap.out ├── 304-lwordwrap.in ├── 304-lwordwrap.out ├── 305-lwordwrap-pivot.in ├── 305-lwordwrap-pivot.out ├── 306-class-to-self.in ├── 306-class-to-self.out ├── 307-class-to-static.in ├── 307-class-to-static.out ├── 308-yoda-bug.in ├── 308-yoda-bug.out ├── 309-empty-list.in ├── 309-empty-list.out ├── 310-allman-style.in ├── 310-allman-style.out ├── 311-allman-style.in ├── 311-allman-style.out ├── 312-allman-and-psr2.in ├── 312-allman-and-psr2.out ├── 313-spacing-and-comments.in ├── 313-spacing-and-comments.out ├── 314-allman-with-space.in ├── 314-allman-with-space.out ├── 315-autoincrement-edge-cases.in ├── 315-autoincrement-edge-cases.out ├── 316-allman-bug.in ├── 316-allman-bug.out ├── 317-wrong-comment-indent.in ├── 317-wrong-comment-indent.out ├── 318-ln-curly.in ├── 318-ln-curly.out ├── 319-align-php-code.in ├── 319-align-php-code.out ├── 320-align-php-code-take-II.in ├── 320-align-php-code-take-II.out ├── 321-align-objop.in ├── 321-align-objop.out ├── 322-and-or-replacement.in ├── 322-and-or-replacement.out ├── 323-align-php-code-take-III.in ├── 323-align-php-code-take-III.out ├── 324-align-objop.in ├── 324-align-objop.out ├── 325-multiline-function.in ├── 325-multiline-function.out ├── 326-space-around-control.in ├── 326-space-around-control.out ├── 327-trim-lines-in-control-blocks.in ├── 327-trim-lines-in-control-blocks.out ├── 328-auto-semicolon.in ├── 328-auto-semicolon.out ├── 329-wrong-indent.in ├── 329-wrong-indent.out ├── 330-wrong-indent.in ├── 330-wrong-indent.out ├── 331-autosemicolon-switch.in ├── 331-autosemicolon-switch.out ├── 332-autosemicolon-switch.in ├── 332-autosemicolon-switch.out ├── 333-strip-spaces.in ├── 333-strip-spaces.out ├── 334-autosemicolon-list.in ├── 334-autosemicolon-list.out ├── 335-autosemicolon-equals-linebreak.in ├── 335-autosemicolon-equals-linebreak.out ├── 336-autosemicolon-failing-case.in ├── 336-autosemicolon-failing-case.out ├── 337-autosemicolon-concat.in ├── 337-autosemicolon-concat.out ├── 338-double-arrow-alignment.in ├── 338-double-arrow-alignment.out ├── 339-align-objop.in ├── 339-align-objop.out ├── 340-add-missing-parentheses.in ├── 340-add-missing-parentheses.out ├── 341-autosemicolon-objop.in ├── 341-autosemicolon-objop.out ├── 342-add-missing-parentheses.in ├── 342-add-missing-parentheses.out ├── 343-add-missing-parentheses-ln.in ├── 343-add-missing-parentheses-ln.out ├── 344-add-missing-parentheses-short-array.in ├── 344-add-missing-parentheses-short-array.out ├── 345-spacing.in ├── 345-spacing.out ├── 346-autosemicolon-conditions.in ├── 346-autosemicolon-conditions.out ├── 347-autosemicolon-if.in ├── 347-autosemicolon-if.out ├── 348-autosemicolon-math.in ├── 348-autosemicolon-math.out ├── 349-bugfix-align-double-arrow.in ├── 349-bugfix-align-double-arrow.out ├── 350-allman-in-switch-block.in ├── 350-allman-in-switch-block.out ├── 351-autosemicolon-closures.in ├── 351-autosemicolon-closures.out ├── 352-spacing-interpolated-value.in ├── 352-spacing-interpolated-value.out ├── 353-autosemicolon.in ├── 353-autosemicolon.out ├── 354-spacing-comments.in ├── 354-spacing-comments.out ├── 355-utf8-align.in ├── 355-utf8-align.out ├── 356-order-visibility.in ├── 356-order-visibility.out ├── 357-spacing-comments.in ├── 357-spacing-comments.out ├── 358-spacing-comments.in ├── 358-spacing-comments.out ├── 359-order-method.in ├── 359-order-method.out ├── 360-align-objop.in ├── 360-align-objop.out ├── 361-order-methods-with-doc-comment.in ├── 361-order-methods-with-doc-comment.out ├── 362-order-methods-and-visibility-with-doc-comment.in ├── 362-order-methods-and-visibility-with-doc-comment.out ├── 363-tight-concat.in ├── 363-tight-concat.out ├── 364-organize-class.in ├── 364-organize-class.out ├── 365-remove-include-parentheses.in ├── 365-remove-include-parentheses.out ├── 366-spacing.in ├── 366-spacing.out ├── 367-reindent-objop.in ├── 367-reindent-objop.out ├── 368-reindent-objop.in ├── 368-reindent-objop.out ├── 369-organize-class.in ├── 369-organize-class.out ├── 370-organize-class.in ├── 370-organize-class.out ├── 371-traits.in ├── 371-traits.out ├── 372-indent-phpdoc.in ├── 372-indent-phpdoc.out ├── 373-double-quotes.in ├── 373-double-quotes.out ├── 374-unused-import-grouped.in ├── 374-unused-import-grouped.out ├── 375-switch-block.in ├── 375-switch-block.out ├── 376-pretty-print-doc-block.in ├── 376-pretty-print-doc-block.out ├── 377-generate-php-docblock.in ├── 377-generate-php-docblock.out ├── 378-fix-open-tag-with-echo.in ├── 378-fix-open-tag-with-echo.out ├── 379-resize-array-addition.in ├── 379-resize-array-addition.out ├── 380-only-order-use.in ├── 380-only-order-use.out ├── 381-reindent-objop.in ├── 381-reindent-objop.out ├── 382-reindent-objop.in ├── 382-reindent-objop.out ├── 383-reindent-comment-closure.in ├── 383-reindent-comment-closure.out ├── 384-reindent-comment-closure.in ├── 384-reindent-comment-closure.out ├── 385-align-equals.in ├── 385-align-equals.out ├── 386-phpdocs-properties.in ├── 386-phpdocs-properties.out ├── 387-autosemicolon.in ├── 387-autosemicolon.out ├── 388-missing-comments-properties.in ├── 388-missing-comments-properties.out ├── 389-phpdoc-param-types.in ├── 389-phpdoc-param-types.out ├── 390-phpdoc-traits-interfaces.in ├── 390-phpdoc-traits-interfaces.out ├── 391-organize-trait-and-interfaces.in ├── 391-organize-trait-and-interfaces.out ├── 392-final-protected.in ├── 392-final-protected.out ├── 393-spacing-control-blocks.in ├── 393-spacing-control-blocks.out ├── 394-indent-equal-blocks.in ├── 394-indent-equal-blocks.out ├── 395-reindent-double-colon.in ├── 395-reindent-double-colon.out ├── 396-reindent-double-colon.in ├── 396-reindent-double-colon.out ├── 397-return-indent.in ├── 397-return-indent.out ├── 398-organize-class-FQN.in ├── 398-organize-class-FQN.out ├── 399-string-in-control-blocks.in ├── 399-string-in-control-blocks.out ├── 400-classtoself.in ├── 400-classtoself.out ├── 401-SortUseNamespace.in ├── 401-SortUseNamespace.out ├── 402-exclamation-mark.in ├── 402-exclamation-mark.out ├── 403-migrate-phpdoc-types-into-function.in ├── 403-migrate-phpdoc-types-into-function.out ├── 404-comments.in ├── 404-comments.out ├── 405-RestoreComments.in ├── 405-RestoreComments.out ├── 406-reindent-comments.in ├── 406-reindent-comments.out ├── 407-space-close-tag.in ├── 407-space-close-tag.out ├── 408-docblock-annotation-use-clauses.in ├── 408-docblock-annotation-use-clauses.out ├── 409-php-ternary-functions.in ├── 409-php-ternary-functions.out ├── 410-remove-extra-semi-colon.in ├── 410-remove-extra-semi-colon.out ├── 411-allman-bug.in ├── 411-allman-bug.out ├── 412-split-else-if.in ├── 412-split-else-if.out ├── 413-spacing.in ├── 413-spacing.out ├── 414-AlignConstVisibilityEquals.in ├── 414-AlignConstVisibilityEquals.out ├── 415-NewLineBeforeReturn.in ├── 415-NewLineBeforeReturn.out ├── 416-echotoprint.in ├── 416-echotoprint.out ├── 417-TrimSpaceBeforeSemicolon.in ├── 417-TrimSpaceBeforeSemicolon.out ├── 418-space-around-control-structures.in ├── 418-space-around-control-structures.out ├── 419-split-curly.in ├── 419-split-curly.out ├── 420-align-php-code-space-indent.in ├── 420-align-php-code-space-indent.out ├── 421-RemoveSemicolonAfterCurly-bug.in ├── 421-RemoveSemicolonAfterCurly-bug.out ├── 422-space-after-exclamation-mark.in ├── 422-space-after-exclamation-mark.out └── autotest.sh ├── vendor ├── autoload.php ├── ccirello │ └── csp │ │ ├── LICENSE │ │ ├── README.md │ │ ├── composer.json │ │ ├── csp.php │ │ ├── example-select.php │ │ └── example.php ├── composer │ ├── ClassLoader.php │ ├── autoload_classmap.php │ ├── autoload_namespaces.php │ ├── autoload_psr4.php │ ├── autoload_real.php │ ├── include_paths.php │ └── installed.json ├── phpunit │ ├── php-code-coverage │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── CONTRIBUTING.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── build.xml │ │ ├── build │ │ │ └── travis-ci.xml │ │ ├── composer.json │ │ ├── phpunit.xml.dist │ │ ├── scripts │ │ │ ├── auto_append.php │ │ │ └── auto_prepend.php │ │ ├── src │ │ │ ├── CodeCoverage.php │ │ │ └── CodeCoverage │ │ │ │ ├── Driver.php │ │ │ │ ├── Driver │ │ │ │ ├── HHVM.php │ │ │ │ └── Xdebug.php │ │ │ │ ├── Exception.php │ │ │ │ ├── Exception │ │ │ │ └── UnintentionallyCoveredCode.php │ │ │ │ ├── Filter.php │ │ │ │ ├── Report │ │ │ │ ├── Clover.php │ │ │ │ ├── Crap4j.php │ │ │ │ ├── Factory.php │ │ │ │ ├── HTML.php │ │ │ │ ├── HTML │ │ │ │ │ ├── Renderer.php │ │ │ │ │ └── Renderer │ │ │ │ │ │ ├── Dashboard.php │ │ │ │ │ │ ├── Directory.php │ │ │ │ │ │ ├── File.php │ │ │ │ │ │ └── Template │ │ │ │ │ │ ├── coverage_bar.html.dist │ │ │ │ │ │ ├── css │ │ │ │ │ │ ├── bootstrap.min.css │ │ │ │ │ │ ├── nv.d3.css │ │ │ │ │ │ └── style.css │ │ │ │ │ │ ├── dashboard.html.dist │ │ │ │ │ │ ├── directory.html.dist │ │ │ │ │ │ ├── directory_item.html.dist │ │ │ │ │ │ ├── file.html.dist │ │ │ │ │ │ ├── file_item.html.dist │ │ │ │ │ │ ├── fonts │ │ │ │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ │ │ │ ├── js │ │ │ │ │ │ ├── bootstrap.min.js │ │ │ │ │ │ ├── d3.min.js │ │ │ │ │ │ ├── holder.js │ │ │ │ │ │ ├── html5shiv.min.js │ │ │ │ │ │ ├── jquery.min.js │ │ │ │ │ │ ├── nv.d3.min.js │ │ │ │ │ │ └── respond.min.js │ │ │ │ │ │ └── method_item.html.dist │ │ │ │ ├── Node.php │ │ │ │ ├── Node │ │ │ │ │ ├── Directory.php │ │ │ │ │ ├── File.php │ │ │ │ │ └── Iterator.php │ │ │ │ ├── PHP.php │ │ │ │ ├── Text.php │ │ │ │ ├── XML.php │ │ │ │ └── XML │ │ │ │ │ ├── Directory.php │ │ │ │ │ ├── File.php │ │ │ │ │ ├── File │ │ │ │ │ ├── Coverage.php │ │ │ │ │ ├── Method.php │ │ │ │ │ ├── Report.php │ │ │ │ │ └── Unit.php │ │ │ │ │ ├── Node.php │ │ │ │ │ ├── Project.php │ │ │ │ │ ├── Tests.php │ │ │ │ │ └── Totals.php │ │ │ │ ├── Util.php │ │ │ │ └── Util │ │ │ │ └── InvalidArgumentHelper.php │ │ └── tests │ │ │ ├── PHP │ │ │ ├── CodeCoverage │ │ │ │ ├── FilterTest.php │ │ │ │ ├── Report │ │ │ │ │ ├── CloverTest.php │ │ │ │ │ └── FactoryTest.php │ │ │ │ └── UtilTest.php │ │ │ └── CodeCoverageTest.php │ │ │ ├── TestCase.php │ │ │ └── _files │ │ │ ├── BankAccount-clover.xml │ │ │ ├── BankAccount.php │ │ │ ├── BankAccountTest.php │ │ │ ├── CoverageClassExtendedTest.php │ │ │ ├── CoverageClassTest.php │ │ │ ├── CoverageFunctionParenthesesTest.php │ │ │ ├── CoverageFunctionParenthesesWhitespaceTest.php │ │ │ ├── CoverageFunctionTest.php │ │ │ ├── CoverageMethodOneLineAnnotationTest.php │ │ │ ├── CoverageMethodParenthesesTest.php │ │ │ ├── CoverageMethodParenthesesWhitespaceTest.php │ │ │ ├── CoverageMethodTest.php │ │ │ ├── CoverageNoneTest.php │ │ │ ├── CoverageNotPrivateTest.php │ │ │ ├── CoverageNotProtectedTest.php │ │ │ ├── CoverageNotPublicTest.php │ │ │ ├── CoverageNothingTest.php │ │ │ ├── CoveragePrivateTest.php │ │ │ ├── CoverageProtectedTest.php │ │ │ ├── CoveragePublicTest.php │ │ │ ├── CoverageTwoDefaultClassAnnotations.php │ │ │ ├── CoveredClass.php │ │ │ ├── CoveredFunction.php │ │ │ ├── NamespaceCoverageClassExtendedTest.php │ │ │ ├── NamespaceCoverageClassTest.php │ │ │ ├── NamespaceCoverageCoversClassPublicTest.php │ │ │ ├── NamespaceCoverageCoversClassTest.php │ │ │ ├── NamespaceCoverageMethodTest.php │ │ │ ├── NamespaceCoverageNotPrivateTest.php │ │ │ ├── NamespaceCoverageNotProtectedTest.php │ │ │ ├── NamespaceCoverageNotPublicTest.php │ │ │ ├── NamespaceCoveragePrivateTest.php │ │ │ ├── NamespaceCoverageProtectedTest.php │ │ │ ├── NamespaceCoveragePublicTest.php │ │ │ ├── NamespaceCoveredClass.php │ │ │ ├── NotExistingCoveredElementTest.php │ │ │ ├── class-with-anonymous-function-clover.xml │ │ │ ├── ignored-lines-clover.xml │ │ │ ├── source_with_class_and_anonymous_function.php │ │ │ ├── source_with_ignore.php │ │ │ ├── source_with_namespace.php │ │ │ ├── source_with_oneline_annotations.php │ │ │ ├── source_without_ignore.php │ │ │ └── source_without_namespace.php │ ├── php-file-iterator │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── ChangeLog.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── composer.json │ │ └── src │ │ │ ├── Facade.php │ │ │ ├── Factory.php │ │ │ └── Iterator.php │ ├── php-text-template │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── LICENSE │ │ ├── README.md │ │ ├── composer.json │ │ └── src │ │ │ └── Template.php │ └── php-token-stream │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── build.xml │ │ ├── build │ │ └── phpunit.xml │ │ ├── composer.json │ │ ├── src │ │ ├── Token.php │ │ └── Token │ │ │ ├── Stream.php │ │ │ └── Stream │ │ │ └── CachingFactory.php │ │ └── tests │ │ ├── Token │ │ ├── ClassTest.php │ │ ├── ClosureTest.php │ │ ├── FunctionTest.php │ │ ├── IncludeTest.php │ │ ├── InterfaceTest.php │ │ └── NamespaceTest.php │ │ ├── TokenTest.php │ │ ├── _fixture │ │ ├── classExtendsNamespacedClass.php │ │ ├── classInNamespace.php │ │ ├── classInScopedNamespace.php │ │ ├── class_with_method_that_declares_anonymous_class.php │ │ ├── class_with_method_that_declares_anonymous_class2.php │ │ ├── closure.php │ │ ├── issue19.php │ │ ├── issue30.php │ │ ├── multipleNamespacesWithOneClassUsingBraces.php │ │ ├── multipleNamespacesWithOneClassUsingNonBraceSyntax.php │ │ ├── source.php │ │ ├── source2.php │ │ ├── source3.php │ │ ├── source4.php │ │ └── source5.php │ │ └── bootstrap.php └── sebastian │ ├── environment │ ├── .gitignore │ ├── .travis.yml │ ├── LICENSE │ ├── README.md │ ├── build.xml │ ├── composer.json │ ├── phpunit.xml.dist │ ├── src │ │ ├── Console.php │ │ └── Runtime.php │ └── tests │ │ ├── ConsoleTest.php │ │ └── RuntimeTest.php │ └── version │ ├── .gitattributes │ ├── .gitignore │ ├── LICENSE │ ├── README.md │ ├── composer.json │ └── src │ └── Version.php └── version.php /.travis.yml: -------------------------------------------------------------------------------- 1 | language: php 2 | sudo: false 3 | 4 | php: 5 | - 7.0 6 | 7 | script: 8 | - cd src && (php -dshort_open_tag=On test.php -v --baseline); 9 | -------------------------------------------------------------------------------- /composer.phar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/composer.phar -------------------------------------------------------------------------------- /fmt.phar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/fmt.phar -------------------------------------------------------------------------------- /fmt.phar.sha1: -------------------------------------------------------------------------------- 1 | c154d6e30c285e675c8fd2a09a754a9ec8b36474 -------------------------------------------------------------------------------- /phpstorm-configuration.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/phpstorm-configuration.png -------------------------------------------------------------------------------- /src/tests-PSR/001-short-open-tag.in: -------------------------------------------------------------------------------- 1 | b->execute( 5 | function ($a){ 6 | return false; 7 | } 8 | ); 9 | } 10 | } -------------------------------------------------------------------------------- /src/tests-PSR/006-wrong-visibility.out: -------------------------------------------------------------------------------- 1 | b->execute( 7 | function ($a) { 8 | return false; 9 | } 10 | ); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/tests-PSR/007-BUG-PSR2ModifierVisibilityStaticOrder.in: -------------------------------------------------------------------------------- 1 | config['video']['binaries']['mediainfo'] . " \"$file\" | grep Video", $video); 4 | 5 | -------------------------------------------------------------------------------- /src/tests-PSR/010-wrong-lower-case.out: -------------------------------------------------------------------------------- 1 | config['video']['binaries']['mediainfo'] . " \"$file\" | grep Video", $video); 4 | -------------------------------------------------------------------------------- /src/tests-PSR/011-wrong-name-change.in: -------------------------------------------------------------------------------- 1 | httpClient = $httpClient; 10 | $this->router = $router; 11 | $this->request = $request; 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /src/tests-PSR/013-Multi-line-function-definition.out: -------------------------------------------------------------------------------- 1 | httpClient = $httpClient; 11 | $this->router = $router; 12 | $this->request = $request; 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/tests-PSR/014-bug-22.in: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /src/tests-PSR/016-bug-42.out: -------------------------------------------------------------------------------- 1 | getServiceLocator() 8 | ->get('STRING')->getRepository('STRING'), 9 | )); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/tests-PSR/020-broken-align-objop.out: -------------------------------------------------------------------------------- 1 | getServiceLocator() 8 | ->get('STRING')->getRepository('STRING'), 9 | )); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/tests-PSR/022-sublime-phpfmt-58.in: -------------------------------------------------------------------------------- 1 | 4 | %2 5 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/tests-PSR/022-sublime-phpfmt-58.out: -------------------------------------------------------------------------------- 1 | 4 | %2 5 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /src/tests-PSR/023-sublime-phpfmt-58.in: -------------------------------------------------------------------------------- 1 | %2 2 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/tests-PSR/023-sublime-phpfmt-58.out: -------------------------------------------------------------------------------- 1 | %2 2 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /src/tests-PSR/024-sublime-phpfmt-58.in: -------------------------------------------------------------------------------- 1 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /src/tests-PSR/024-sublime-phpfmt-58.out: -------------------------------------------------------------------------------- 1 | ignoreUnreadableDirs 7 | ? function ($stderr) { return; } 8 | : function ($stderr) { throw new AccessDeniedException($stderr); }; 9 | 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/tests-PSR/027-wrong-visibility.out: -------------------------------------------------------------------------------- 1 | ignoreUnreadableDirs 7 | ? function ($stderr) {return;} 8 | : function ($stderr) {throw new AccessDeniedException($stderr);}; 9 | 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/tests-PSR/028-method-name-propagation.in: -------------------------------------------------------------------------------- 1 | setHelp(<<method()} 7 | EOF 8 | ); 9 | } 10 | protected function execute() { 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/tests-PSR/030-dirty-heredoc.out: -------------------------------------------------------------------------------- 1 | setHelp(<<method()} 9 | EOF 10 | ); 11 | } 12 | protected function execute() 13 | { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /src/tests-PSR/031-visibility-coverage.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests-PSR/034-invalid-close-tag-removal.out: -------------------------------------------------------------------------------- 1 | instanceOf; 3 | -------------------------------------------------------------------------------- /src/tests-PSR/036-wrong-lowercase.out: -------------------------------------------------------------------------------- 1 | instanceOf; 3 | -------------------------------------------------------------------------------- /src/tests-PSR/037-empty-function.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests-PSR/038-t-var.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests-PSR/043-short-open-tags.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests-PSR/044-short-open-tags.out: -------------------------------------------------------------------------------- 1 | 4 | -------------------------------------------------------------------------------- /src/tests-PSR/047-short-open-tags.out: -------------------------------------------------------------------------------- 1 | 5 | 'bbb', 9 | 'ddd' => 'a', 10 | ]; 11 | 12 | $x = [ 13 | /* 14 | * TEST 15 | */ 16 | 'a' => 'bbb', 17 | 'ddd' => 'a', 18 | ]; -------------------------------------------------------------------------------- /src/tests-PSR/048-reindent-source.out: -------------------------------------------------------------------------------- 1 | 'bbb', 9 | 'ddd' => 'a', 10 | ]; 11 | 12 | $x = [ 13 | /* 14 | * TEST 15 | */ 16 | 'a' => 'bbb', 17 | 'ddd' => 'a', 18 | ]; 19 | -------------------------------------------------------------------------------- /src/tests/000-break_line.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/000-break_line.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/003-namespace_and_uses.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/003-namespace_and_uses.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/005-BUGFIX_array_dereference_from_object.in: -------------------------------------------------------------------------------- 1 | (string) $obj->prop->prop2->prop3[$i]->prop4[$j]->prop5, 4 | 'k2' => $v 5 | ); -------------------------------------------------------------------------------- /src/tests/005-BUGFIX_array_dereference_from_object.out: -------------------------------------------------------------------------------- 1 | (string) $obj->prop->prop2->prop3[$i]->prop4[$j]->prop5, 4 | 'k2' => $v, 5 | ); -------------------------------------------------------------------------------- /src/tests/006-BUGFIX_heredoc.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/007-uses.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/008-array_multiline.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/008-array_multiline.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/009-while_while.in: -------------------------------------------------------------------------------- 1 | 15 | -------------------------------------------------------------------------------- /src/tests/009-while_while.out: -------------------------------------------------------------------------------- 1 | 17 | -------------------------------------------------------------------------------- /src/tests/010-BUGFIX_deference_in_mixed_array.in: -------------------------------------------------------------------------------- 1 | $a[$b[self::KEY_NAME]], 4 | ConstantBag::TEXT_1 => isset($a['text1']) ? $a['text1']:'', 5 | ConstantBag::TEXT_2 => isset($a['text2']) ? $a['text2']:'', 6 | ); 7 | -------------------------------------------------------------------------------- /src/tests/010-BUGFIX_deference_in_mixed_array.out: -------------------------------------------------------------------------------- 1 | $a[$b[self::KEY_NAME]], 4 | ConstantBag::TEXT_1 => isset($a['text1']) ? $a['text1'] : '', 5 | ConstantBag::TEXT_2 => isset($a['text2']) ? $a['text2'] : '', 6 | ); 7 | -------------------------------------------------------------------------------- /src/tests/011-BUGFIX_else_colon.in: -------------------------------------------------------------------------------- 1 | 2 | HTML 3 | 4 | HTML 5 | -------------------------------------------------------------------------------- /src/tests/011-BUGFIX_else_colon.out: -------------------------------------------------------------------------------- 1 | 2 | HTML 3 | 4 | HTML 5 | -------------------------------------------------------------------------------- /src/tests/013-BUGFIX_remark_between_parentheses_and_curly.in: -------------------------------------------------------------------------------- 1 | 'v', //TODO 6 | 'k' => 'v', #TODO 7 | ); 8 | 9 | $array = [ 10 | 'a', 11 | // TODO 12 | 'k' => 'v', //TODO 13 | 'k' => 'v', #TODO 14 | ]; 15 | 16 | func($a 17 | // comment 18 | ); 19 | 20 | $a->m1() 21 | ->m2() // comment 22 | ->m3(); 23 | -------------------------------------------------------------------------------- /src/tests/014-BUGFIX_comment_within_array.out: -------------------------------------------------------------------------------- 1 | 'v', //TODO 6 | 'k' => 'v', #TODO 7 | ); 8 | 9 | $array = [ 10 | 'a', 11 | // TODO 12 | 'k' => 'v', //TODO 13 | 'k' => 'v', #TODO 14 | ]; 15 | 16 | func($a 17 | // comment 18 | ); 19 | 20 | $a->m1() 21 | ->m2() // comment 22 | ->m3(); 23 | -------------------------------------------------------------------------------- /src/tests/017-BUGFIX_broken_auto_curly_2.in: -------------------------------------------------------------------------------- 1 | 0) { 7 | for ($i = 1;$i <= $count_spaces;$i++) { 8 | $new_txt .= " "; 9 | } 10 | } 11 | do { 12 | $cmd = cmd (); 13 | } 14 | while (true); 15 | -------------------------------------------------------------------------------- /src/tests/017-BUGFIX_broken_auto_curly_2.out: -------------------------------------------------------------------------------- 1 | 0) { 6 | for ($i = 1; $i <= $count_spaces; $i++) { 7 | $new_txt .= " "; 8 | } 9 | } 10 | do { 11 | $cmd = cmd(); 12 | } while (true); 13 | -------------------------------------------------------------------------------- /src/tests/022-BUGFIX_misinteraction_between_param_and_array.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/027-comments_breaking_syntax.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/030-broken_indentation_2.in: -------------------------------------------------------------------------------- 1 | 4 | array( 5 | 'k' => 0, 6 | 'l' => 1 7 | ) 8 | ); -------------------------------------------------------------------------------- /src/tests/038-broken-array-ln.out: -------------------------------------------------------------------------------- 1 | array( 4 | 'k' => 0, 5 | 'l' => 1, 6 | ), 7 | ); -------------------------------------------------------------------------------- /src/tests/039-broken-mix-short-long-arrays.in: -------------------------------------------------------------------------------- 1 | [12,15], 4 | "l" => [$a, $b], 5 | "m" => [$a['b'], 2], 6 | ); 7 | -------------------------------------------------------------------------------- /src/tests/039-broken-mix-short-long-arrays.out: -------------------------------------------------------------------------------- 1 | [12, 15], 4 | "l" => [$a, $b], 5 | "m" => [$a['b'], 2], 6 | ); 7 | -------------------------------------------------------------------------------- /src/tests/040-broken-alignment.in: -------------------------------------------------------------------------------- 1 | $line) { 4 | if (true) { 5 | $a = $b; 6 | } 7 | elseif (false) { 8 | echo "never here"; 9 | } 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/tests/041-broken-else-elseif.out: -------------------------------------------------------------------------------- 1 | $line) { 4 | if (true) { 5 | $a = $b; 6 | } elseif (false) { 7 | echo "never here"; 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /src/tests/043-clever-array.in: -------------------------------------------------------------------------------- 1 | 'v') 10 | ); 11 | $a = array( 12 | array( 13 | 'k' => 'v', 14 | 'k' => 'v' 15 | ) 16 | ); -------------------------------------------------------------------------------- /src/tests/043-clever-array.out: -------------------------------------------------------------------------------- 1 | 'v'), 10 | ); 11 | $a = array( 12 | array( 13 | 'k' => 'v', 14 | 'k' => 'v', 15 | ), 16 | ); -------------------------------------------------------------------------------- /src/tests/044-space-between-functions.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/045-remark-after-constant.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/049-align-comments.in: -------------------------------------------------------------------------------- 1 | execute(CONSTANT_NAME, 8, //comment2 5 | array($this, 'do'), $var); 6 | } -------------------------------------------------------------------------------- /src/tests/051-wrong-line-merge.out: -------------------------------------------------------------------------------- 1 | execute(CONSTANT_NAME, 8, //comment2 5 | array($this, 'do'), $var); 6 | } -------------------------------------------------------------------------------- /src/tests/052-wrong-line-deletion-between-attr-and-if.in: -------------------------------------------------------------------------------- 1 | get()) { 5 | $arr["k"] = $kk; 6 | } -------------------------------------------------------------------------------- /src/tests/052-wrong-line-deletion-between-attr-and-if.out: -------------------------------------------------------------------------------- 1 | get()) { 5 | $arr["k"] = $kk; 6 | } -------------------------------------------------------------------------------- /src/tests/053-wrong-alignment.in: -------------------------------------------------------------------------------- 1 | LL || $obj->LL->l(__CLASS__, sprintf("Msg [%d] : %s", $obj2->gs(), $obj2->ge())); 4 | !$llll_ttt || $obj->ssss_ttttt($obj3->gv(), $ttttt_ppppppp, ConstantBAG::CONSTANT, $obj2, $dddd_rrr); 5 | -------------------------------------------------------------------------------- /src/tests/053-wrong-alignment.out: -------------------------------------------------------------------------------- 1 | LL || $obj->LL->l(__CLASS__, sprintf("Msg [%d] : %s", $obj2->gs(), $obj2->ge())); 4 | !$llll_ttt || $obj->ssss_ttttt($obj3->gv(), $ttttt_ppppppp, ConstantBAG::CONSTANT, $obj2, $dddd_rrr); 5 | -------------------------------------------------------------------------------- /src/tests/054-wrong-line-break-merge.in: -------------------------------------------------------------------------------- 1 | execute(CONSTANT_NAME, 8, //comment2 5 | array($this/*->*/, 'do'), $var); 6 | } -------------------------------------------------------------------------------- /src/tests/055-wrong-alignment-within-comment.out: -------------------------------------------------------------------------------- 1 | execute(CONSTANT_NAME, 8, //comment2 5 | array($this/*->*/, 'do'), $var); 6 | } -------------------------------------------------------------------------------- /src/tests/056-wrong-extra-line.in: -------------------------------------------------------------------------------- 1 | l($vhi, $rq, ConstantBag::D); // comment 4 | 5 | $vhi = $this->v($arr); 6 | -------------------------------------------------------------------------------- /src/tests/060-wrong-line-merge-after-comment.out: -------------------------------------------------------------------------------- 1 | l($vhi, $rq, ConstantBag::D); // comment 4 | 5 | $vhi = $this->v($arr); 6 | -------------------------------------------------------------------------------- /src/tests/062-double-colon.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/062-double-colon.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/063-two-commands-same-line.in: -------------------------------------------------------------------------------- 1 | $v]); -------------------------------------------------------------------------------- /src/tests/066-double-arrow.out: -------------------------------------------------------------------------------- 1 | $v]); -------------------------------------------------------------------------------- /src/tests/067-else-plus-if.in: -------------------------------------------------------------------------------- 1 | Method1() 4 | ->Method2() 5 | ->Method3($data) 6 | ; 7 | 8 | $object = $this->Method1() 9 | ->Method2() 10 | ->Method3($data) 11 | ; 12 | 13 | $this->Method1() 14 | ->Method2() 15 | ->Method3($data) 16 | ; -------------------------------------------------------------------------------- /src/tests/070-obj-op-indent.out: -------------------------------------------------------------------------------- 1 | Method1() 4 | ->Method2() 5 | ->Method3($data) 6 | ; 7 | 8 | $object = $this->Method1() 9 | ->Method2() 10 | ->Method3($data) 11 | ; 12 | 13 | $this->Method1() 14 | ->Method2() 15 | ->Method3($data) 16 | ; -------------------------------------------------------------------------------- /src/tests/072-wrong-objop-short-array.in: -------------------------------------------------------------------------------- 1 | ConstangBag::ConstantName, 5 | ]; 6 | 7 | $obj = new ClassObjects(); 8 | $arr = array( 9 | ConstangBag::ConstantName => ConstangBag::ConstantName, 10 | ); -------------------------------------------------------------------------------- /src/tests/072-wrong-objop-short-array.out: -------------------------------------------------------------------------------- 1 | ConstangBag::ConstantName, 5 | ]; 6 | 7 | $obj = new ClassObjects(); 8 | $arr = array( 9 | ConstangBag::ConstantName => ConstangBag::ConstantName, 10 | ); -------------------------------------------------------------------------------- /src/tests/073-wrong-extra-comma.in: -------------------------------------------------------------------------------- 1 | 1, 12 | $ccc => 10, 13 | ); 14 | $bbbb = array( 15 | $b => 0, 16 | $cccc => ' 17 | $a = array( 18 | 0 => 1, 19 | 10 => 10, 20 | ); 21 | ' 22 | ); 23 | 24 | -------------------------------------------------------------------------------- /src/tests/074-wrong-align-in-str.out: -------------------------------------------------------------------------------- 1 | 1, 11 | $ccc => 10, 12 | ); 13 | $bbbb = array( 14 | $b => 0, 15 | $cccc => ' 16 | $a = array( 17 | 0 => 1, 18 | 10 => 10, 19 | ); 20 | ', 21 | ); 22 | -------------------------------------------------------------------------------- /src/tests/075-empty-lines.in: -------------------------------------------------------------------------------- 1 | $ct) { 3 | foreach ($ct as $cy => $nm) { 4 | foreach ($nm as $nmv) { 5 | echo $nmv; 6 | } 7 | } 8 | } 9 | ?> -------------------------------------------------------------------------------- /src/tests/081-double-arrow-misalign.out: -------------------------------------------------------------------------------- 1 | $ct) { 3 | foreach ($ct as $cy => $nm) { 4 | foreach ($nm as $nmv) { 5 | echo $nmv; 6 | } 7 | } 8 | } 9 | ?> -------------------------------------------------------------------------------- /src/tests/082-wrong-linebreak-after-public.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/085-uses-not-removing-empty-line.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/088-chain-effect.in: -------------------------------------------------------------------------------- 1 | name : null; 3 | 4 | -------------------------------------------------------------------------------- /src/tests/088-chain-effect.out: -------------------------------------------------------------------------------- 1 | name : null; 4 | } 5 | -------------------------------------------------------------------------------- /src/tests/089-aired-out-spacing-bug.in: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | rel=icon> 5 | 6 | -------------------------------------------------------------------------------- /src/tests/094-wrong-indentation.out: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | rel=icon> 5 | 6 | -------------------------------------------------------------------------------- /src/tests/096-use-clause-within-docblocks.in: -------------------------------------------------------------------------------- 1 | = 0 && is_array($this->tkns[$i]) && $this->tkns[$i][0] === T_WHITESPACE); 4 | } else { 5 | while (++$i < sizeof($this->tkns) - 1 && is_array($this->tkns[$i]) && $this->tkns[$i][0] === T_WHITESPACE); 6 | } 7 | -------------------------------------------------------------------------------- /src/tests/098-wrong-while-position.out: -------------------------------------------------------------------------------- 1 | = 0 && is_array($this->tkns[$i]) && $this->tkns[$i][0] === T_WHITESPACE); 4 | } else { 5 | while (++$i < sizeof($this->tkns) - 1 && is_array($this->tkns[$i]) && $this->tkns[$i][0] === T_WHITESPACE); 6 | } 7 | -------------------------------------------------------------------------------- /src/tests/099-wrong-while-position-II.in: -------------------------------------------------------------------------------- 1 | ptr; 3 | while (--$i >= 0 && is_array($this->tkns[$i]) && $this->tkns[$i][0] === T_WHITESPACE); 4 | -------------------------------------------------------------------------------- /src/tests/099-wrong-while-position-II.out: -------------------------------------------------------------------------------- 1 | ptr; 3 | while (--$i >= 0 && is_array($this->tkns[$i]) && $this->tkns[$i][0] === T_WHITESPACE); 4 | -------------------------------------------------------------------------------- /src/tests/100-array-heredoc.in: -------------------------------------------------------------------------------- 1 | 6 | a;b; -------------------------------------------------------------------------------- /src/tests/102-two-commands-same-line.out: -------------------------------------------------------------------------------- 1 | 7 | a;b; -------------------------------------------------------------------------------- /src/tests/103-bug-614.in: -------------------------------------------------------------------------------- 1 | = 0; --$i) { 5 | 6 | } 7 | 8 | for ($i = $i; $i >= 0;--$i) { 9 | 10 | } 11 | -------------------------------------------------------------------------------- /src/tests/106-decrement-spacing-issue.out: -------------------------------------------------------------------------------- 1 | = 0; --$i) { 4 | 5 | } 6 | 7 | for ($i = $i; $i >= 0; --$i) { 8 | 9 | } 10 | -------------------------------------------------------------------------------- /src/tests/108-indentation-bug.in: -------------------------------------------------------------------------------- 1 | A->{$b}){ 3 | 4 | } -------------------------------------------------------------------------------- /src/tests/109-spacing-bug.out: -------------------------------------------------------------------------------- 1 | A->{$b}) { 3 | 4 | } -------------------------------------------------------------------------------- /src/tests/110-st-reference-space-bug.in: -------------------------------------------------------------------------------- 1 | [$a], 4 | $a[$b]=> $c, 5 | $b->getKey()=> $d, 6 | $b->{$c}=> $e, 7 | ]; 8 | -------------------------------------------------------------------------------- /src/tests/122-spacing-bug.out: -------------------------------------------------------------------------------- 1 | [$a], 4 | $a[$b] => $c, 5 | $b->getKey() => $d, 6 | $b->{$c} => $e, 7 | ]; 8 | -------------------------------------------------------------------------------- /src/tests/123-amazon-bug.in: -------------------------------------------------------------------------------- 1 | $headerVal) $params->{$headerKey} = (string)$headerVal; -------------------------------------------------------------------------------- /src/tests/123-amazon-bug.out: -------------------------------------------------------------------------------- 1 | $headerVal) { 3 | $params->{$headerKey} = (string) $headerVal; 4 | } 5 | -------------------------------------------------------------------------------- /src/tests/124-wrong-curly-in-string.in: -------------------------------------------------------------------------------- 1 | $b){ 3 | } 4 | -------------------------------------------------------------------------------- /src/tests/153-normalize-is-not-equals.out: -------------------------------------------------------------------------------- 1 | bar(1) 4 | //->baz(2) 5 | ; -------------------------------------------------------------------------------- /src/tests/164-wrong-align-objop.out: -------------------------------------------------------------------------------- 1 | bar(1) 4 | //->baz(2) 5 | ; -------------------------------------------------------------------------------- /src/tests/165-add-missing-parentheses.in: -------------------------------------------------------------------------------- 1 | [ 4 | 'yyyyaas' => 'aaaa', 5 | 'code' => func([ 6 | "aaa" => 1, 7 | "aaaaaa" => 1, 8 | "aaaaaaaaa" => 1, 9 | ]), 10 | 'yyyyaasa' => 'aaaa', 11 | ], 12 | ]; 13 | -------------------------------------------------------------------------------- /src/tests/167-auto-align-error-take-III.out: -------------------------------------------------------------------------------- 1 | [ 4 | 'yyyyaas' => 'aaaa', 5 | 'code' => func([ 6 | "aaa" => 1, 7 | "aaaaaa" => 1, 8 | "aaaaaaaaa" => 1, 9 | ]), 10 | 'yyyyaasa' => 'aaaa', 11 | ], 12 | ]; 13 | -------------------------------------------------------------------------------- /src/tests/168-multi-line-array.in: -------------------------------------------------------------------------------- 1 | join(','); 7 | 8 | SomeClass::join(','); 9 | -------------------------------------------------------------------------------- /src/tests/175-join-to-implode.out: -------------------------------------------------------------------------------- 1 | join(','); 7 | 8 | SomeClass::join(','); 9 | -------------------------------------------------------------------------------- /src/tests/177-bug-sublime-77.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/185-remove-include-parentheses-coverage.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/186-wrong-merge.in: -------------------------------------------------------------------------------- 1 | 10 | -------------------------------------------------------------------------------- /src/tests/187-encapsulate-namespaces-inline-html.out: -------------------------------------------------------------------------------- 1 | 9 | -------------------------------------------------------------------------------- /src/tests/190-tight-concat.in: -------------------------------------------------------------------------------- 1 | attribute 4 | ->with(['a' => 'b']) 5 | ->into($var); 6 | 7 | $obj->attribute 8 | ->with() 9 | ->into($var); 10 | } 11 | 12 | $obj 13 | ->with(['a' => 'b']) 14 | ->into($var); 15 | 16 | $obj->attribute 17 | ->with(['a' => 'b']) 18 | ->into($var); 19 | 20 | -------------------------------------------------------------------------------- /src/tests/194-wrong-objop-indent.out: -------------------------------------------------------------------------------- 1 | attribute 4 | ->with(['a' => 'b']) 5 | ->into($var); 6 | 7 | $obj->attribute 8 | ->with() 9 | ->into($var); 10 | } 11 | 12 | $obj 13 | ->with(['a' => 'b']) 14 | ->into($var); 15 | 16 | $obj->attribute 17 | ->with(['a' => 'b']) 18 | ->into($var); 19 | -------------------------------------------------------------------------------- /src/tests/195-several-spacing-issues.in: -------------------------------------------------------------------------------- 1 | method(); 5 | (new Obj())->connect(); 6 | } 7 | 8 | 9 | function doSomething2() { 10 | $app->method(); 11 | (new Obj())->connect(); 12 | } -------------------------------------------------------------------------------- /src/tests/196-regression-align-objop.out: -------------------------------------------------------------------------------- 1 | method(); 5 | (new Obj())->connect(); 6 | } 7 | 8 | function doSomething2() { 9 | $app->method(); 10 | (new Obj())->connect(); 11 | } -------------------------------------------------------------------------------- /src/tests/197-encapsulate-namespaces-close-tag.in: -------------------------------------------------------------------------------- 1 | "b", 4 | ); 5 | 6 | $var3 = << "b", 14 | ); 15 | 16 | $varArray = [ 17 | "c" => "d", 18 | ]; 19 | 20 | $var4 = ""; 21 | 22 | $varArray = [ 23 | "c" => "d", 24 | ]; 25 | -------------------------------------------------------------------------------- /src/tests/201-BUGFIX_heredoc_wrong_alignment.out: -------------------------------------------------------------------------------- 1 | "b", 4 | ); 5 | 6 | $var3 = << "b", 14 | ); 15 | 16 | $varArray = [ 17 | "c" => "d", 18 | ]; 19 | 20 | $var4 = ""; 21 | 22 | $varArray = [ 23 | "c" => "d", 24 | ]; 25 | -------------------------------------------------------------------------------- /src/tests/204-wrong-alignment.in: -------------------------------------------------------------------------------- 1 | thing; 5 | } 6 | 7 | /** 8 | */ 9 | public function action() { 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/tests/204-wrong-alignment.out: -------------------------------------------------------------------------------- 1 | thing; 5 | } 6 | 7 | /** 8 | */ 9 | public function action() { 10 | } 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/tests/206-wrong-paren-count-reindent-objop.in: -------------------------------------------------------------------------------- 1 | cmd('string', array(new SomeClass('bar'))) 3 | ->setValue('value'); 4 | -------------------------------------------------------------------------------- /src/tests/206-wrong-paren-count-reindent-objop.out: -------------------------------------------------------------------------------- 1 | cmd('string', array(new SomeClass('bar'))) 3 | ->setValue('value'); 4 | -------------------------------------------------------------------------------- /src/tests/207-wrong-reindent-obj-count.in: -------------------------------------------------------------------------------- 1 | methodA() 5 | ->methodB(CONSTANT_NAME, function($a){}) 6 | ->methodC(true) 7 | ->methodD(); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/tests/207-wrong-reindent-obj-count.out: -------------------------------------------------------------------------------- 1 | methodA() 5 | ->methodB(CONSTANT_NAME, function ($a) {}) 6 | ->methodC(true) 7 | ->methodD(); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/tests/208-objop-reindent-two-obj.in: -------------------------------------------------------------------------------- 1 | method( 3 | new SomeAmazingClass('en', array('messages' => array('a' => 'old_a', 'b' => 'old_b'))), 4 | new SomeAmazingClass('en', array('messages' => array('a' => 'old_a', 'b' => 'old_b'))) 5 | )->methodB(); -------------------------------------------------------------------------------- /src/tests/208-objop-reindent-two-obj.out: -------------------------------------------------------------------------------- 1 | method( 3 | new SomeAmazingClass('en', array('messages' => array('a' => 'old_a', 'b' => 'old_b'))), 4 | new SomeAmazingClass('en', array('messages' => array('a' => 'old_a', 'b' => 'old_b'))) 5 | )->methodB(); -------------------------------------------------------------------------------- /src/tests/209-join-to-implode.in: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/210-missing-semi-colon-and-curly-block.out: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/211-spacing-semicolon-comments.in: -------------------------------------------------------------------------------- 1 | action()->action2(); /** @var Someclass $obj2 */ 3 | -------------------------------------------------------------------------------- /src/tests/211-spacing-semicolon-comments.out: -------------------------------------------------------------------------------- 1 | action()->action2(); /** @var Someclass $obj2 */ 3 | -------------------------------------------------------------------------------- /src/tests/212-missing-semi-colon-and-curly-block.in: -------------------------------------------------------------------------------- 1 | xxsomething; 4 | 5 | echo $a 6 | ->firstThis 7 | ->something; 8 | 9 | echo $a->firstThis 10 | ->something; 11 | 12 | echo $a->firstThis; 13 | 14 | -------------------------------------------------------------------------------- /src/tests/214-reindentobjop-coverage.out: -------------------------------------------------------------------------------- 1 | something; 4 | 5 | echo $a 6 | ->firstThis 7 | ->something; 8 | 9 | echo $a->firstThis 10 | ->something; 11 | 12 | echo $a->firstThis; 13 | -------------------------------------------------------------------------------- /src/tests/215-missing-semi-colon-and-curly-block-coverage.in: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/215-missing-semi-colon-and-curly-block-coverage.out: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/216-missing-semi-colon-and-curly-block-coverage.in: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/216-missing-semi-colon-and-curly-block-coverage.out: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/217-wrong-new-line.in: -------------------------------------------------------------------------------- 1 | get()&$var); 3 | ($obj->get()&($var)); 4 | ($obj->property &$var); 5 | $b = &$a; 6 | function a(Typehint &$var){ 7 | 8 | } 9 | -------------------------------------------------------------------------------- /src/tests/219-st_reference_spacing.out: -------------------------------------------------------------------------------- 1 | get() & $var); 3 | ($obj->get() & ($var)); 4 | ($obj->property & $var); 5 | $b = &$a; 6 | function a(Typehint &$var) { 7 | 8 | } 9 | -------------------------------------------------------------------------------- /src/tests/220-spacing-operators.in: -------------------------------------------------------------------------------- 1 | property + array(); 3 | $params + array(); 4 | $now->format('U') + (int) $expires; 5 | foreach ($this->_files as &$file) { 6 | } 7 | 8 | foreach ($this->_files as $k => &$file) { 9 | } 10 | array(&$Schema, $table); -------------------------------------------------------------------------------- /src/tests/220-spacing-operators.out: -------------------------------------------------------------------------------- 1 | property + array(); 3 | $params + array(); 4 | $now->format('U') + (int) $expires; 5 | foreach ($this->_files as &$file) { 6 | } 7 | 8 | foreach ($this->_files as $k => &$file) { 9 | } 10 | array(&$Schema, $table); -------------------------------------------------------------------------------- /src/tests/221-cakephp-style.in: -------------------------------------------------------------------------------- 1 | property->{$var}; 6 | break; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /src/tests/223-wrong-spacing-tcurly.out: -------------------------------------------------------------------------------- 1 | property->{$var}; 6 | break; 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /src/tests/224-spacing-issues.in: -------------------------------------------------------------------------------- 1 | property['key']+$obj->property2; 9 | 10 | $ascii = chr(200+(($var-($var % 32)) / 32)); 11 | 12 | $var[$key[0]] = $var[$key[0]]-1; 13 | -------------------------------------------------------------------------------- /src/tests/224-spacing-issues.out: -------------------------------------------------------------------------------- 1 | property['key'] + $obj->property2; 9 | 10 | $ascii = chr(200 + (($var - ($var % 32)) / 32)); 11 | 12 | $var[$key[0]] = $var[$key[0]] - 1; 13 | -------------------------------------------------------------------------------- /src/tests/225-cakephp-style-references.in: -------------------------------------------------------------------------------- 1 | array("{$type}0.alias"=> $start) 5 | ); 6 | ?> 7 | -------------------------------------------------------------------------------- /src/tests/226-spacing-issue-doublearrow.out: -------------------------------------------------------------------------------- 1 | array("{$type}0.alias" => $start), 5 | ); 6 | ?> 7 | -------------------------------------------------------------------------------- /src/tests/227-missing-visibility.in: -------------------------------------------------------------------------------- 1 | $option) { 6 | printf("%${len}", 1); 7 | } 8 | } 9 | 10 | protected function _interactive() { 11 | } 12 | } -------------------------------------------------------------------------------- /src/tests/227-missing-visibility.out: -------------------------------------------------------------------------------- 1 | $option) { 6 | printf("%${len}", 1); 7 | } 8 | } 9 | 10 | protected function _interactive() { 11 | } 12 | } -------------------------------------------------------------------------------- /src/tests/228-cakephp-coverage.in: -------------------------------------------------------------------------------- 1 | 'value', 6 | ) 7 | }else{// comment 8 | 9 | } 10 | ?> 11 | -------------------------------------------------------------------------------- /src/tests/228-cakephp-coverage.out: -------------------------------------------------------------------------------- 1 | 'value', 6 | ) 7 | } else { // comment 8 | 9 | } 10 | ?> 11 | -------------------------------------------------------------------------------- /src/tests/229-cakephp-underscore-normalization.in: -------------------------------------------------------------------------------- 1 | property{$i} = 10; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/tests/232-wrong-space-variable-variables.out: -------------------------------------------------------------------------------- 1 | property{$i} = 10; 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/tests/233-wrong-ln.in: -------------------------------------------------------------------------------- 1 | methodA() 7 | ->methodB(); 8 | } 9 | 10 | public function theMethod2() { 11 | $this->methodA() 12 | ->methodB($this->nestedMethodC( 13 | )); 14 | } 15 | } -------------------------------------------------------------------------------- /src/tests/238-wrong-reindentobjop.out: -------------------------------------------------------------------------------- 1 | methodA() 7 | ->methodB(); 8 | } 9 | 10 | public function theMethod2() { 11 | $this->methodA() 12 | ->methodB($this->nestedMethodC( 13 | )); 14 | } 15 | } -------------------------------------------------------------------------------- /src/tests/239-merge-open-with-namespace.in: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/247-missing-semi-colon-and-curly-block-coverage.out: -------------------------------------------------------------------------------- 1 | x -------------------------------------------------------------------------------- /src/tests/248-fix-bug-include-parentheses-removal.in: -------------------------------------------------------------------------------- 1 | foo() 3 | ->bar() // comment 4 | ->baz() 5 | ; 6 | 7 | $c = $d 8 | ->asdf() /* hello */ 9 | ->fdsa(); 10 | 11 | $x = 1234; // sup -------------------------------------------------------------------------------- /src/tests/256-spacing-parentheses-comment.out: -------------------------------------------------------------------------------- 1 | foo() 3 | ->bar() // comment 4 | ->baz() 5 | ; 6 | 7 | $c = $d 8 | ->asdf() /* hello */ 9 | ->fdsa(); 10 | 11 | $x = 1234; // sup -------------------------------------------------------------------------------- /src/tests/259-extra-alignments-alignment.in: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 |

5 | 6 |

7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /src/tests/267-wrong-html.out: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 11 | 12 |
4 |

5 | 6 |

7 |
9 | 10 |
13 | -------------------------------------------------------------------------------- /src/tests/268-long-array.in: -------------------------------------------------------------------------------- 1 | {a}[ 3 | 1 4 | ]; 5 | 6 | $a()[ 7 | 1 8 | ]; -------------------------------------------------------------------------------- /src/tests/271-improving-short-array-detection.out: -------------------------------------------------------------------------------- 1 | {a}[ 3 | 1 4 | ]; 5 | 6 | $a()[ 7 | 1 8 | ]; -------------------------------------------------------------------------------- /src/tests/272-wordwrap.in: -------------------------------------------------------------------------------- 1 | $b; 5 | } 6 | -------------------------------------------------------------------------------- /src/tests/294-t-spaceship.out: -------------------------------------------------------------------------------- 1 | $b; 5 | } 6 | -------------------------------------------------------------------------------- /src/tests/295-double-to-single-quotes.in: -------------------------------------------------------------------------------- 1 | {$b}->c): 0 !== $b->{$a}->c; 9 | -------------------------------------------------------------------------------- /src/tests/300-scalar-hint-and-return-types.out: -------------------------------------------------------------------------------- 1 | {$b}->c) : 0 !== $b->{$a}->c; 9 | -------------------------------------------------------------------------------- /src/tests/301-open-tag-with-echo.in: -------------------------------------------------------------------------------- 1 | 2 | 2 | announce("{$obj->goodbye()}"); 8 | } 9 | -------------------------------------------------------------------------------- /src/tests/308-yoda-bug.out: -------------------------------------------------------------------------------- 1 | announce("{$obj->goodbye()}"); 8 | } 9 | -------------------------------------------------------------------------------- /src/tests/309-empty-list.in: -------------------------------------------------------------------------------- 1 | {$v}->attr[$c]->$dynattr; 4 | 5 | ++$var[$v]; 6 | 7 | ++${$var}->{$v . "string"}->attr[$c]->$dynattr; 8 | 9 | $var = $v++; 10 | 11 | $var + $v++; 12 | 13 | $var++ + $v; 14 | 15 | func($v++); 16 | 17 | func($var, $v++); 18 | 19 | $var[$v++]; 20 | 21 | echo $var++; 22 | -------------------------------------------------------------------------------- /src/tests/317-wrong-comment-indent.in: -------------------------------------------------------------------------------- 1 | select(['id', 'username']) 3 | ->from('user') 4 | ->where(['pk_id' => $this->organization]) 5 | ->offset($paging->offset) 6 | ->limit($paging->limit) 7 | ->all(); -------------------------------------------------------------------------------- /src/tests/324-align-objop.out: -------------------------------------------------------------------------------- 1 | select(['id', 'username']) 3 | ->from('user') 4 | ->where(['pk_id' => $this->organization]) 5 | ->offset($paging->offset) 6 | ->limit($paging->limit) 7 | ->all(); -------------------------------------------------------------------------------- /src/tests/327-trim-lines-in-control-blocks.in: -------------------------------------------------------------------------------- 1 | Some text 10 | HtmlOutput; 11 | endif; -------------------------------------------------------------------------------- /src/tests/329-wrong-indent.out: -------------------------------------------------------------------------------- 1 | Some text 10 | HtmlOutput; 11 | endif; -------------------------------------------------------------------------------- /src/tests/330-wrong-indent.in: -------------------------------------------------------------------------------- 1 | Some text 10 | HtmlOutput; 11 | endif; -------------------------------------------------------------------------------- /src/tests/330-wrong-indent.out: -------------------------------------------------------------------------------- 1 | Some text 10 | HtmlOutput; 11 | endif; -------------------------------------------------------------------------------- /src/tests/331-autosemicolon-switch.in: -------------------------------------------------------------------------------- 1 | aaa = 'bbbb' 8 | $gaApi->ccc = 'ddddd'; 9 | $gaApi->eee = 'fffff'; 10 | $gaApi->ggg = 'hhhh' 11 | }); 12 | -------------------------------------------------------------------------------- /src/tests/336-autosemicolon-failing-case.out: -------------------------------------------------------------------------------- 1 | aaa = 'bbbb'; 8 | $gaApi->ccc = 'ddddd'; 9 | $gaApi->eee = 'fffff'; 10 | $gaApi->ggg = 'hhhh'; 11 | }); 12 | -------------------------------------------------------------------------------- /src/tests/337-autosemicolon-concat.in: -------------------------------------------------------------------------------- 1 | quote($v); 10 | }, array_keys($row), $row 11 | ) 12 | ) 13 | . '' 14 | -------------------------------------------------------------------------------- /src/tests/337-autosemicolon-concat.out: -------------------------------------------------------------------------------- 1 | quote($v); 10 | }, array_keys($row), $row 11 | ) 12 | ) 13 | . ''; 14 | -------------------------------------------------------------------------------- /src/tests/339-align-objop.in: -------------------------------------------------------------------------------- 1 | b 3 | ->c; 4 | 5 | $two = a->b($x->y) 6 | ->c; -------------------------------------------------------------------------------- /src/tests/339-align-objop.out: -------------------------------------------------------------------------------- 1 | b 3 | ->c; 4 | 5 | $two = a->b($x->y) 6 | ->c; -------------------------------------------------------------------------------- /src/tests/340-add-missing-parentheses.in: -------------------------------------------------------------------------------- 1 | x; 6 | $d = (new D)->y(); -------------------------------------------------------------------------------- /src/tests/340-add-missing-parentheses.out: -------------------------------------------------------------------------------- 1 | x; 6 | $d = (new D())->y(); -------------------------------------------------------------------------------- /src/tests/341-autosemicolon-objop.in: -------------------------------------------------------------------------------- 1 | b 4 | ->c; 5 | 6 | $two = a->b($x->y) 7 | ->c; -------------------------------------------------------------------------------- /src/tests/341-autosemicolon-objop.out: -------------------------------------------------------------------------------- 1 | b 4 | ->c; 5 | 6 | $two = a->b($x->y) 7 | ->c; -------------------------------------------------------------------------------- /src/tests/342-add-missing-parentheses.in: -------------------------------------------------------------------------------- 1 | get('a') / 6 | $obj->get('b')) 7 | 8 | , 2); -------------------------------------------------------------------------------- /src/tests/348-autosemicolon-math.out: -------------------------------------------------------------------------------- 1 | get('a') / 6 | $obj->get('b')) 7 | 8 | , 2); -------------------------------------------------------------------------------- /src/tests/349-bugfix-align-double-arrow.in: -------------------------------------------------------------------------------- 1 | $fac; 6 | } 7 | -------------------------------------------------------------------------------- /src/tests/349-bugfix-align-double-arrow.out: -------------------------------------------------------------------------------- 1 | $fac; 6 | } 7 | -------------------------------------------------------------------------------- /src/tests/350-allman-in-switch-block.in: -------------------------------------------------------------------------------- 1 | false, // COMMENT 4 | 5 | 'k2' => [// COMMENT 6 | ], 7 | ]; 8 | 9 | 10 | $a = array( 11 | 'k1' => false, // COMMENT 12 | 13 | 'k2' => array(// COMMENT 14 | ), 15 | ); -------------------------------------------------------------------------------- /src/tests/354-spacing-comments.out: -------------------------------------------------------------------------------- 1 | false, // COMMENT 4 | 5 | 'k2' => [ // COMMENT 6 | ], 7 | ]; 8 | 9 | $a = array( 10 | 'k1' => false, // COMMENT 11 | 12 | 'k2' => array( // COMMENT 13 | ), 14 | ); -------------------------------------------------------------------------------- /src/tests/355-utf8-align.in: -------------------------------------------------------------------------------- 1 | 'as', 4 | 'ytė\b' => 'is', 5 | 'iūtė\b' => 'ius', 6 | 'utė\b' => 'us', 7 | ); 8 | -------------------------------------------------------------------------------- /src/tests/355-utf8-align.out: -------------------------------------------------------------------------------- 1 | 'as', 4 | 'ytė\b' => 'is', 5 | 'iūtė\b' => 'ius', 6 | 'utė\b' => 'us', 7 | ); 8 | -------------------------------------------------------------------------------- /src/tests/356-order-visibility.in: -------------------------------------------------------------------------------- 1 | 'hey', 4 | 'hey' => 'hey', 5 | PHP_VERSION => 'hey', 6 | DateTime::class => 'hey', 7 | ]; 8 | -------------------------------------------------------------------------------- /src/tests/358-spacing-comments.out: -------------------------------------------------------------------------------- 1 | 'hey', 4 | 'hey' => 'hey', 5 | PHP_VERSION => 'hey', 6 | DateTime::class => 'hey', 7 | ]; 8 | -------------------------------------------------------------------------------- /src/tests/359-order-method.in: -------------------------------------------------------------------------------- 1 | list = (new Query)->select(['id', 'name']) 4 | ->where(['sex' => 1]) 5 | ->all(); -------------------------------------------------------------------------------- /src/tests/360-align-objop.out: -------------------------------------------------------------------------------- 1 | list = (new Query)->select(['id', 'name']) 4 | ->where(['sex' => 1]) 5 | ->all(); -------------------------------------------------------------------------------- /src/tests/361-order-methods-with-doc-comment.in: -------------------------------------------------------------------------------- 1 | include_path); 3 | require_once(App::Config()->Config->include_path); 4 | -------------------------------------------------------------------------------- /src/tests/365-remove-include-parentheses.out: -------------------------------------------------------------------------------- 1 | include_path; 3 | require_once App::Config()->Config->include_path; 4 | -------------------------------------------------------------------------------- /src/tests/366-spacing.in: -------------------------------------------------------------------------------- 1 | bar( 4 | 'aoeu' 5 | )-> 6 | baz(); 7 | 8 | $foo->bar( 9 | 'aoeu' 10 | ) 11 | ->baz(); 12 | 13 | 14 | $foo->bar( 15 | 'aoeu' 16 | )-> 17 | //comment1 18 | baz(); 19 | 20 | $foo->bar( 21 | 'aoeu' 22 | ) 23 | //comment2 24 | ->baz(); -------------------------------------------------------------------------------- /src/tests/367-reindent-objop.out: -------------------------------------------------------------------------------- 1 | bar( 4 | 'aoeu' 5 | )-> 6 | baz(); 7 | 8 | $foo->bar( 9 | 'aoeu' 10 | ) 11 | ->baz(); 12 | 13 | $foo->bar( 14 | 'aoeu' 15 | )-> 16 | //comment1 17 | baz(); 18 | 19 | $foo->bar( 20 | 'aoeu' 21 | ) 22 | //comment2 23 | ->baz(); -------------------------------------------------------------------------------- /src/tests/368-reindent-objop.in: -------------------------------------------------------------------------------- 1 | bar( 4 | 'aoeu' 5 | )-> 6 | baz(); 7 | 8 | $foo->bar( 9 | 'aoeu' 10 | ) 11 | ->baz(); 12 | 13 | 14 | $foo->bar( 15 | 'aoeu' 16 | )-> 17 | //comment1 18 | baz(); 19 | 20 | $foo->bar( 21 | 'aoeu' 22 | ) 23 | //comment2 24 | ->baz(); -------------------------------------------------------------------------------- /src/tests/368-reindent-objop.out: -------------------------------------------------------------------------------- 1 | bar( 4 | 'aoeu' 5 | )-> 6 | baz(); 7 | 8 | $foo->bar( 9 | 'aoeu' 10 | ) 11 | ->baz(); 12 | 13 | $foo->bar( 14 | 'aoeu' 15 | )-> 16 | //comment1 17 | baz(); 18 | 19 | $foo->bar( 20 | 'aoeu' 21 | ) 22 | //comment2 23 | ->baz(); -------------------------------------------------------------------------------- /src/tests/369-organize-class.in: -------------------------------------------------------------------------------- 1 | 4 | */ 5 | class BlogController 6 | { 7 | public function reports($request) 8 | { 9 | return $request; 10 | } 11 | } 12 | 13 | //passes:GeneratePHPDoc -------------------------------------------------------------------------------- /src/tests/377-generate-php-docblock.out: -------------------------------------------------------------------------------- 1 | 4 | */ 5 | class BlogController { 6 | /** 7 | * @param $request 8 | * @return mixed 9 | */ 10 | public function reports($request) { 11 | return $request; 12 | } 13 | } 14 | 15 | //passes:GeneratePHPDoc -------------------------------------------------------------------------------- /src/tests/378-fix-open-tag-with-echo.in: -------------------------------------------------------------------------------- 1 | 4 |
5 | 6 | $model, 8 | 'attributes' => [ 9 | 'id', 10 | [ 11 | 'label' => 'name', 12 | 'value' => $model->name, 13 | ], 14 | ], 15 | ]);?> 16 |
-------------------------------------------------------------------------------- /src/tests/378-fix-open-tag-with-echo.out: -------------------------------------------------------------------------------- 1 | 4 |
5 | 6 | $model, 8 | 'attributes' => [ 9 | 'id', 10 | [ 11 | 'label' => 'name', 12 | 'value' => $model->name, 13 | ], 14 | ], 15 | ]);?> 16 |
-------------------------------------------------------------------------------- /src/tests/379-resize-array-addition.in: -------------------------------------------------------------------------------- 1 | $parentIds]; 3 | -------------------------------------------------------------------------------- /src/tests/379-resize-array-addition.out: -------------------------------------------------------------------------------- 1 | $parentIds]; 3 | -------------------------------------------------------------------------------- /src/tests/380-only-order-use.in: -------------------------------------------------------------------------------- 1 | locker->lock($self->id, function () use ($self) { 5 | // comment a 6 | // comment b 7 | $self->method(); 8 | }); 9 | 10 | $this->locker->lock($selfid, function () use ($self) { 11 | // comment c 12 | // comment d 13 | $self->method(); 14 | }); 15 | -------------------------------------------------------------------------------- /src/tests/383-reindent-comment-closure.out: -------------------------------------------------------------------------------- 1 | locker->lock($self->id, function () use ($self) { 5 | // comment a 6 | // comment b 7 | $self->method(); 8 | }); 9 | 10 | $this->locker->lock($selfid, function () use ($self) { 11 | // comment c 12 | // comment d 13 | $self->method(); 14 | }); 15 | -------------------------------------------------------------------------------- /src/tests/384-reindent-comment-closure.in: -------------------------------------------------------------------------------- 1 | locker->lock($self->id, function () use ($self) { 5 | // comment a 6 | // comment b 7 | $self->method(); 8 | }); 9 | 10 | $this->locker->lock($selfid, function () use ($self) { 11 | // comment c 12 | // comment d 13 | $self->method(); 14 | }); 15 | -------------------------------------------------------------------------------- /src/tests/384-reindent-comment-closure.out: -------------------------------------------------------------------------------- 1 | locker->lock($self->id, function () use ($self) { 5 | // comment a 6 | // comment b 7 | $self->method(); 8 | }); 9 | 10 | $this->locker->lock($selfid, function () use ($self) { 11 | // comment c 12 | // comment d 13 | $self->method(); 14 | }); 15 | -------------------------------------------------------------------------------- /src/tests/385-align-equals.in: -------------------------------------------------------------------------------- 1 | locker->lock($self->id, function () use ($self) { 16 | $a = 0; 17 | $bb = 0; 18 | $ccc = 0; 19 | }); 20 | -------------------------------------------------------------------------------- /src/tests/385-align-equals.out: -------------------------------------------------------------------------------- 1 | locker->lock($self->id, function () use ($self) { 16 | $a = 0; 17 | $bb = 0; 18 | $ccc = 0; 19 | }); 20 | -------------------------------------------------------------------------------- /src/tests/387-autosemicolon.in: -------------------------------------------------------------------------------- 1 | baz; 6 | -------------------------------------------------------------------------------- /src/tests/395-reindent-double-colon.out: -------------------------------------------------------------------------------- 1 | baz; 6 | -------------------------------------------------------------------------------- /src/tests/396-reindent-double-colon.in: -------------------------------------------------------------------------------- 1 | baz; 5 | -------------------------------------------------------------------------------- /src/tests/396-reindent-double-colon.out: -------------------------------------------------------------------------------- 1 | baz; 5 | -------------------------------------------------------------------------------- /src/tests/397-return-indent.in: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/407-space-close-tag.out: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/tests/408-docblock-annotation-use-clauses.in: -------------------------------------------------------------------------------- 1 | 2) {?> 2 | a link 3 | 4 | -------------------------------------------------------------------------------- /src/tests/419-split-curly.out: -------------------------------------------------------------------------------- 1 | 2) {?> 2 | a link 3 | 4 | -------------------------------------------------------------------------------- /src/tests/421-RemoveSemicolonAfterCurly-bug.in: -------------------------------------------------------------------------------- 1 | stop(); 3 | 4 | $writer = new PHP_CodeCoverage_Report_HTML; 5 | $writer->process($coverage, '/tmp/coverage'); 6 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kodeclan/phpfmt/8b47fc05a90ead8ceedcb2af7ca7af1ea8461408/src/vendor/phpunit/php-code-coverage/src/CodeCoverage/Report/HTML/Renderer/Template/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassExtendedTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageClassTest.php: -------------------------------------------------------------------------------- 1 | publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageFunctionParenthesesTest.php: -------------------------------------------------------------------------------- 1 | publicMethod(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageMethodTest.php: -------------------------------------------------------------------------------- 1 | publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageNoneTest.php: -------------------------------------------------------------------------------- 1 | publicMethod(); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPrivateTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotProtectedTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageNotPublicTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoveragePrivateTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoverageProtectedTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoveragePublicTest.php: -------------------------------------------------------------------------------- 1 | 6 | */ 7 | public function testSomething() 8 | { 9 | $o = new CoveredClass; 10 | $o->publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/CoveredFunction.php: -------------------------------------------------------------------------------- 1 | publicMethod(); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/vendor/phpunit/php-code-coverage/tests/_files/source_without_ignore.php: -------------------------------------------------------------------------------- 1 |