"Memoize property assignments" treating array as always empty? #10069
Unanswered
AlbinoDrought
asked this question in
Q&A
Replies: 1 comment
-
It's not something you're doing wrong per se. You may disable this setting but you'll probably discover that you also depend heavily on it in other places There's just no perfect solution here. What I try to do in those cases is to make the emptyness check (or any other check) also encapsulated in a method, that way Psalm can't see that the variable is empty and then complain |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
https://psalm.dev/r/f10e0af67c
Is there something I am doing wrong in the above example, or do I just need to disable this setting?
Cheers
Beta Was this translation helpful? Give feedback.
All reactions