It makes things so simple, I really wish other languages had it. Today in five or six places I wrote something like
_innerObject?.Dispose();
instead of
if (_innerObject != null) _innerObject.Dispose();
Long live DRY principle! Of course, our friend Juan Gandhi will probably say it is a Maybe monad (hey, how come in this day and age Chrome spell checker does not know the word “monad”?!). Anyhow, I wish this kind of shortcut were present in JavaScript. I really miss it. The proposal is already there, but I am not sure how long it will take it to get to the standard, if at all.
Permalink
I just loved it.
Permalink
AFAIK, VS team took the idea from Nemerle.
Permalink
This is entirely possible. I wish more languages adopted this idea.