Add a linter rule for parent references
Summary:
Add a linter rule to detect static method calls which should reference the parent class instead of a hardcoded class reference. For example, consider the following:
class SomeClass extends AnotherClass { public function someMethod() { AnotherClass::someOtherMethod(); } }
This should instead be written as:
class SomeClass extends AnotherClass { public function someMethod() { parent::someOtherMethod(); } }
Test Plan: Added unit tests.
Reviewers: epriestley, Blessed Reviewers
Reviewed By: epriestley, Blessed Reviewers
Subscribers: Korvin, epriestley
Differential Revision: https://secure.phabricator.com/D14443