Possible Duplicate:
Difference between try-catch syntax for function
Few days ago I was reading a book about C++ (it cloud be even a Bjarne Stroustrup's book) and I found such approach in chapter about exceptions:
class Foo :
public Bar
{
// ...
};
// ...
Foo::Foo
try :
Bar ()
{
// ...
}
catch (const std::exception& error)
{
// ...
}
I don't know why but this construction looks weird for me. However it's very powerful, because it gives me ability to handle exception thrown by base class "inside" toplevel constructor.
I'm using C++ for few years and I thought, that I know this language pretty good... What's wrong with this approach? Why it's not mentioned often event in C++ books?