The question you wanna ask yourself, though, is: do you want to start copying C# syntaxes/operators verbatim, and at what point does that become “not VB like, anymore”?
Case in point: Oxygene is arguable much closer to C# than VB is (even though it too is very distinct), and ?= would feel totally out of place, just copied to Oxygene, since we don’t use “?” for “nullable” logic anywhere ion Oxygene. If we were to add this feature to Oxygene, it would need to look different.
ok, that’s fine. In the end I’ll take your word for whats VB-like and what isn’t, I just wanted to make sure you (all) did consider this aspect of the language design process.
I agree with you that this is not really VB-ish; I would have designed it complete different.
But it is like this since VB2010; question mark fore everything that is nullable.
This was the only missing piece, so I took the same approach to make it fit in the already existing way of doing nullables.
How I should have done it if nullable wasn’t already implemented: Dim i As Nullable(of Integer) instead of Dim i As Integer? i = SafeNull(myString.Length) instead of i = myString?.Length AssignIfNotNothing(i, 25) instead of i ?= 25
But we have to deal with backward compatibility where we have to follow the path of wrong design decisions that were made by Microsoft in the past.
And as everything that is nullable in VB is designed as ? by Microsoft, the best is to follow this bad design to keep things logical.