Using the Null Conditional Operator to check values on objects which might be null
问题 I've been playing with C# 6's Null Conditional Operator (more info here). I really like the syntax and I think it makes the code much more readable however I think it is questionable as to what exactly the code is going to do when you come across checking the value of a property on an object which itself might be null. For example, if I had a class with a decimal property on it and I wanted a conditional check on the value of that decimal, I would write something like: if (foo?.Bar > max) { /