What happens when assertions fail? It depends.
Java throws an exception.
C# and Visual Basic display a dialog box by default but provide an interface for extending and customizing program behavior when assertions fail.
In C and C++, the default behavior for assertion violations is to abort the program immediately. Not surprisingly, many C and C++ programmers create their own assertion-checking macros that are, well, "smarter".
What is the correct behavior then?
Some library developers would answer that there is no single correct behavior, and they'll point out at all the different behaviors people find useful. Why make a difficult design decision when you can shift that responsibility to the user?
What this train of thought is missing is that when an assertion fires, we can no longer reason about the state of the program; there is no way to know what will happen if the program is not terminated.
"But it might be important to minimize the damage! In some instances, ignoring a particular assertion might be better than terminating the program!"
Certainly, except that when something the programmer considered impossible has just happened, all bets are off. Aborting seems drastic? Indeed it is, but any other alternative would be like making a zombie run a marathon.
Besides, it isn't always realistic to assume that the user knows the correct answer. What would you reply to
Assertion failure: "Your nuclear reactor has overheated. Abort, Debug, Ignore?"
Formatting hint: when posting comments, surround code blocks in [@ and @].