4 ms·
No, you get a nullable warning for that as well. You also need to change the reference type to nullable. I am convinced that some people will just init the prop
by AtNightWeCode 4y ago
No, you get a nullable warning for that as well. You also need to change the reference type to nullable. I am convinced that some people will just init the properties with new(). And by that hide the null errors. Easily the hardest bugs to track down is when things fails long after the real error occur. I think they could have come with a better solution to the problem.
- Deukhoofd 4y agoIf you assign it with "= null", you get the warning. If you assign it with "= null!" (note the exclamation mark, the null-forgiving operator), you do not.
- AtNightWeCode 4y agoOk, correct. I did not know about that. Thanks for the clarification.