Is it possible to annotate Generator/Traversable/Iterable non-empty? #9191
Unanswered
mateusz-wu
asked this question in
Q&A
Replies: 1 comment
-
It's not possible right now, I suggest just suppressing for now |
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
-
I have a method returning
Generator<string>
.When passing it's result to a method requiring
non-empty-list/array
of course I get"possibly undefined string"
Of course if it was about arrays/lists I'd return non-empty-array and problem would be solved, but not with Generators/Iterables.
Is it possible to annotate Generator/iterable non empty?
Thanks a lot
Beta Was this translation helpful? Give feedback.
All reactions