-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Make the parameter 'args' no-nullable in the public ConsoleHost APIs
#13429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@PoshChan please remind me in 24 hours |
.Net team confirmed that it is not null for Main() - right signature |
Why is that? Yes, there is a null assignment in
|
It is a public API too :-) It would be not right using but possible. |
What is desired behavior for null? Throw? |
True, but it's less likely to be used like the
Yes, throw, but with |
|
@rjmholt, this is the reminder you requested 24 hours ago |
|
🎉 Handy links: |
PR Summary
This is a follow-up on #11482
We actually don't expect
argsto containnullvalue in it. For example, the use ofargsinGetSwitchKeyat here indicates we are not expecting an element ofargsisnull, and many other places likeParseFile./cc @iSazonov Maybe we should validate if
argscontains anynullelements, maybe that's not necessary given it has been working fine so far, but either way, I'm deferring that to a separate PR.PR Context
PR Checklist
.h,.cpp,.cs,.ps1and.psm1files have the correct copyright headerWIP:or[ WIP ]to the beginning of the title (theWIPbot will keep its status check atPendingwhile the prefix is present) and remove the prefix when the PR is ready.