top | item 30436030

(no title)

talaketu | 4 years ago

English also has the phrase "the exception proves the rule" - and it's just swell when our general code handles special cases.

I would have not have thought an unreachable host was exceptional, given that it's quite normal.

discuss

order

gumby|4 years ago

In this aphorism, “prove” has an archaic meaning: “tests the rule”.

The point is that handling the host unreachable is almost always semantically higher level than the code opening the connection. This the code opening doesn’t implement the policy of what to do when the situation occurs. In the case, say, of a hard-coded address then it’s possible the author of that piece of code does know how to handle a host unreachable case.

talaketu|4 years ago

Yes, this is said, but the meaning of "prove" (which is related to "probe") has not really changed very much at all compared to "test" - a word which in this sense is a metonym from the fired pot used for assay of metal. The meaning in "mathematical proof" or "prove beyond reasonable doubt" or "prove your love" doesn't really diverge significantly from this so-called archaic meaning - a demonstration to show.

On the software abstraction, exceptions are simply a convenient implicit control flow device for handling the alternate path when an intended state cannot be achieved. I don't follow the paper's argument that "current exception design is suboptimal for efficient implementation" - but I would not be surprised considering the lifetime issues.