On Sun, Mar 29, 2009 at 11:25 AM, Robert Ramey
I'm investigating boost exception to see if it is helpful in a particular instance. I start by looking at the first Tutorial.
I can't see how this is better than
struc my_error : public std::exception { int m_ errno; my_error(int errno) : m_errno(errno) {} };
... throw my_error(errno)
try { ... } catch(my_error e){ cerr << e; }
What am I missing here? This first example is two compilicated in that it requires that I delve into a bunch of other stuff (operator << for exception data?) and it doesn't provide any motivation. I think it would be more useful if it "spoon fed" the reader (me in this case) a little more. Something like:
Traditional simple example like that above. explanation of why the example isn't "good enough" simple example reformulated using boost exception explanation of how this addresses the short comings of the original version.
Now that you point it out, I realize that this type of example is necessary. I'll add it to the documentation for 1.39. Emil Dotchevski Reverge Studios, Inc. http://www.revergestudios.com/reblog/index.php?n=ReCode