Hacker News new | ask | show | jobs
by gr3ml1n 498 days ago
I can think of situations where all four make sense. Not sure what you mean?

result+no error: data returned, no error happened. - Typical function call where you want some data.

no Result+error: nothing to return, error happened. - That typical call failed.

result+error: partial result, up to error. - Wrote x bytes to disk, then ran out of space.

no result+no error: nothing to return, no error. - Data for a passed query. Nothing came back, but that's not an error.

1 comments

But not every situation. Make illegal state unreprestable is a good ideal.