Hacker News new | ask | show | jobs
by ams6110 4712 days ago
A programmer calls a subroutine to save user-data on the hard disk without checking whether the operation was successful or not.

This might not be blind-faith. "Fail-fast" is a legitimate pattern where you don't check for errors, you just let the program fail/terminate immediately.

2 comments

But in this case, if you don't check the return value of for example the write() system call, it's more a case of "fail silently" than "fail-fast", which is perhaps the most dangerous form of bug that a program can have.
I find that this is my natural strategy; I only test functions explicitly when they fail.