]> khamidou — GitHub mirrors - arcanist.git/commit
Improve PHP compatibility linter
authorJoshua Spence <josh@joshuaspence.com>
Mon, 10 Aug 2015 20:48:56 +0000 (06:48 +1000)
committerJoshua Spence <josh@joshuaspence.com>
Mon, 10 Aug 2015 20:48:56 +0000 (06:48 +1000)
commitf43b74c6052f10b54bb5c97215fdc02d8935226f
tree34ade45d96187d964b07cbaea18f4b113bbade24
parent9e65fc65164a3fc82e6027f77b111fd8e9362afc
Improve PHP compatibility linter

Summary: Ref T8674. Adds to `ArcanistPHPCompatibilityXHPASTLinterRule` such that an error is raised whenever `self` or `$this` is used in an anonymous closure prior to PHP 5.4.

Test Plan: Added test cases.

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: Korvin

Maniphest Tasks: T8674

Differential Revision: https://secure.phabricator.com/D13841
src/lint/linter/__tests__/xhpast/php54-features.lint-test
src/lint/linter/xhpast/rules/ArcanistPHPCompatibilityXHPASTLinterRule.php