logoalt Hacker News

pjmlpyesterday at 2:42 PM2 repliesview on HN

On the contrary, because there we have 40 years of security exploits to prove otherwise, and Linux kernel has plenty of CVEs.

C# solution doesn't work, most projects never adopted it, because it is a mess to use with third party libraries that never bothered to add the required annotations, hence why it is still a warning and optional to this day.


Replies

mrsmrtssyesterday at 6:51 PM

I’m not sure which .NET libraries you are referring to, but all the ones we use have nullable reference types enabled. If you configure warnings as errors (as you should), then it works exceptionally well. Even if you were to use a library where nullable reference types are not enabled, you only need to check for null once during the library call, rather than everywhere in your codebase.

neonsunsetyesterday at 11:44 PM

What? NRTs are used everywhere with WarningAsErrors:nullable also gaining popularity. Whatever environment you are dealing with C# in, if it’s the opposite I suggest getting away from that ASAP.

show 1 reply