| > Cute, but is this actually needed? It's one more thing to remember, one more thing to know the subtleties of, and for what? Hi there! C# language designer here :-) In this case, it's more that this feature made the language more uniform. We've had `?.` for more than 10 years now, and it worked properly for most expressions except assignment. During that time we got a large amount of feedback from users asking for this, and we commonly ran into it ourselves. At a language and impl level, these were both very easy to add in, so this was a low cost Qol feature that just made things nicer and more consistent. > It feels like the C# designers have a hard time saying "no" to ideas coming their way. We say no to more than 99% of requests. > We're trading brevity for complexity There's no new keyword here. And this makes usage and processing of `?.` more uniform and consistent. Imo, that is a good thing. You have less complexity that way. |
p.s. I will take the opportunity to say that I dream of the day when C# gets bounded sum types with compiler enforced exhaustive pattern matching. It feels like we are soooo close with records and switch expression, but just missing one or two pieces to make it work.