]> khamidou — GitHub mirrors - arcanist.git/commit
Add a linter rule for spacing after a cast
authorJoshua Spence <josh@joshuaspence.com>
Sun, 17 May 2015 22:06:05 +0000 (08:06 +1000)
committerJoshua Spence <josh@joshuaspence.com>
Sun, 17 May 2015 22:07:43 +0000 (08:07 +1000)
commit2e66d03c68e470748aea87960402b94285cf19d0
tree8ce9b90ac640f5d85f59a8cab271bb75f2f246a2
parente1a057b4d9384ea2c83d61257e776afca8edcf0b
Add a linter rule for spacing after a cast

Summary: Ref T7409. Add a linter rule to ensure that a cast is not followed by a space. This is largely based on [[https://github.com/squizlabs/PHP_CodeSniffer/blob/master/CodeSniffer/Standards/Generic/Sniffs/Formatting/NoSpaceAfterCastSniff.php | Generic_Sniffs_Formatting_NoSpaceAfterCastSniff]].

Test Plan: Added unit tests.

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley, #blessed_reviewers

Subscribers: Korvin, epriestley

Maniphest Tasks: T7409

Differential Revision: https://secure.phabricator.com/D12321
src/lint/linter/ArcanistXHPASTLinter.php
src/lint/linter/__tests__/xhpast/cast-spacing.lint-test [new file with mode: 0644]