ForbiddenThisUseContexts: allow for array access by jrfnl · Pull Request #781 · PHPCompatibility/PHPCompatibility
For classes which implement the `ArrayAccess` interface, such as the `ArrayObject` class, using `$this['key']` is a perfectly fine, working syntax and unsetting an item in the object using that syntax will still work and is unaffected by the changes in PHP 7.1. The sniff, however, would throw a false positive for this. This PR fixes that. Includes unit tests. Fixes 780
jrfnl
mentioned this pull request
wimg approved these changes Dec 23, 2018
wimg
deleted the
feature/780-forbiddenthisusage-bug
branch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters