Comment

Comment by fauigerzigerk

I agree that null pointers have never been this huge problem compared to many others.

But I think it is rather convenient to formally specify which pointers can be null and which ones can not.

How do I tell the users of my library wether they can pass null into my API? How do I stop people from putting "just in case" null checks into code that doesn't need it, obscuring the logic of the program and burdening callers with yet more error handling?

In my opinion, the "modern" approach of using some sort of Maybe type is just far more productive.

parent fauigerzigerk 10 months ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton