New keyword: empty #4435
Unanswered
TheTrigger
asked this question in
Language Ideas
Replies: 3 comments 2 replies
-
See #3435. |
Beta Was this translation helpful? Give feedback.
0 replies
-
With length patterns it would be Length patterns were initially discussed in https://github.com/dotnet/csharplang/blob/master/meetings/2020/LDM-2020-12-16.md |
Beta Was this translation helpful? Give feedback.
1 reply
-
New keyword is very likely to be rejected. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
We already reached
is null
andis not null
Now what about
is [not] empty
for enumerables?I guess null == empty goes against some null conventions...
However, I don't like parentheses, they distract me, and I feel the
empty
word very uncomfortable to type... but..."free us from
string.IsNullOrEmpty
anditems.Any()
" 😁Beta Was this translation helpful? Give feedback.
All reactions