All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

Re-examining the 'Billion Dollar Mistake': Why Null Pointers Are Not the Primary Memory Safety Problem

By

signa11

4mo ago· 19 min readenInsight

Summary

The article challenges the conventional wisdom about null pointers being a 'Billion Dollar Mistake' by Tony Hoare. It argues that null pointer dereferences are actually the easiest class of invalid memory addresses to catch at runtime and are the least common type of memory errors in unsafe languages. The author contends that proposed solutions to eliminate null pointers have significant trade-offs that aren't obvious, and the perception of null pointers as a problem stems from an 'individual-element mindset' rather than considering the broader context of memory safety issues.

Key quotes

· 5 pulled
null pointer dereferences are empirically the easiest class of invalid memory addresses to catch at runtime
the least common kind of invalid memory addresses that happen in memory unsafe languages
the trivial solutions to remove the 'problem' null pointers have numerous trade-offs which are not obvious
the cause of why people think it is a 'problem' comes from a specific kind of individual-element mindset
Most people have probably heard of the Billion Dollar Mistake before, which was coined/invented by Tony Hoare: the inventor of null references
Snippet from the RSS feed
TL;DR null pointer dereferences are empirically the easiest class of invalid memory addresses to catch at runtime, and are the least common kind of invalid memory addresses that happen in memory unsafe languages. The trivial solutions to remove the “probl

You might also wanna read