[OffsetAccessOnStringRule] Initial implementation#1310
Conversation
9c8fa0a to
9be9be9
Compare
|
I believe part of this is already covered by https://github.com/phpstan/phpstan/blob/master/src/Rules/Arrays/NonexistentOffsetInArrayDimFetchRule.php and the other part would be covered by my suggestion in #1307. But it's always good to at least recycle these tests to corresponding rules once they're implemented so I'm leaving this open. |
|
See https://phpstan.org/r/4b9affb1252f4ccab55ef797703101cb - it's already handled. It does not show up here https://phpstan.org/r/2445f50bdd5edf1fd8cee57bf45fd38d because |
|
I don't understand. This should report and error: https://phpstan.org/r/dbda208449aa9798e2901be22bfba409 So should this: |
|
There's no rule for checking that |
|
To summarize - there's already a rule for I also suggested in #1307 to add a rule that checks whether |
|
@ondrejmirtes I see. Sorry for the confusion 😆 |
be23b86 to
c6a8cd1
Compare
5904f1c to
99bb3a9
Compare
|
I've recycled your tests and used them with the current rules and typesystem in this commit: 7a630b8 Thanks! |
|
@ondrejmirtes Cool, thanks 🙂 |
Closes #1308