]> khamidou — GitHub mirrors - arcanist.git/commit
Add a linter rule for lowercase function names
authorJoshua Spence <josh@joshuaspence.com>
Wed, 22 Apr 2015 12:02:09 +0000 (22:02 +1000)
committerJoshua Spence <josh@joshuaspence.com>
Wed, 22 Apr 2015 12:06:49 +0000 (22:06 +1000)
commitab4eac6f31801ca841b1939969063e4a7dc74f90
treecd792c0a45efedb38b76b1aac935438238775012
parenta9ebe1cb4ffc9ebfa1ef8a87ef51e0b8b026cb42
Add a linter rule for lowercase function names

Summary: Ref T7409. Adds `ArcanistXHPASTLinter::LINT_LOWERCASE_FUNCTIONS` to ensure that builtin PHP functions are lowercased. Based on [[https://github.com/squizlabs/PHP_CodeSniffer/blob/master/CodeSniffer/Standards/Squiz/Sniffs/PHP/LowercasePHPFunctionsSniff.php | Squiz_Sniffs_PHP_LowercasePHPFunctionsSniff]].

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/D12377
src/lint/linter/ArcanistXHPASTLinter.php
src/lint/linter/__tests__/xhpast/lowercase-functions.lint-test [new file with mode: 0644]