From: David Abrahams (abrahams_at_[hidden])
Date: 2001-04-11 12:06:23
----- Original Message -----
From: "Gary Powell" <Gary.Powell_at_[hidden]>
> > It comes down to a question of definitions: is passing a 0 to the
> > constructor misuse, or is it allowed? If it's misuse I want an
Oops. I meant "is calling a zero any-function misuse?"
> Pass in a zero should be allowed. Sometimes I initialize things in one
> and fill them in at another. Calling it is a misuse. But for released code
> want an exception thrown, not a crash.
Then you need a tunable assertion.
> The idea that released products should crash is one that needs to be
I never believed that. They should be correct ;-)
> But hey I write games and if you lose your character, because I wrote
> code, its just an excuse for you to play another 1K hrs and build it up
> again. No seriously, if you can afford the code space, not crashing is the
> way to go. That's heart monitors, games, airplane control systems. Come to
> think of it, there are no computer programs in which a released version
> should just crash. Shut down with a "I can't go on" is so much nicer.
> Sometimes you can actually do something useful on the way out.
> By this I mean I understand that some embedded systems are too code space
> contained to use exceptions. But by in large, the more robust the code
> written the better off I and my customers are. It's much easier to ship a
> game that doesn't do some feature in an edge case than one that crashes in
> that same edge case. Preferably I'll fix it, but if its missed. I hate
> working until 4am on a death march to get the crashing bugs out.
Which is one reason why some people need assertions, at least in debug
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk