Boost logo

Boost :

From: Emil Dotchevski (emildotchevski_at_[hidden])
Date: 2020-05-30 05:43:54


On Fri, May 29, 2020 at 10:27 PM Krystian Stasiowski via Boost <
boost_at_[hidden]> wrote:
> trailing underscores
> following names that are public doesn't look particularly right; makes it
> look like you're using you
> aren't supposed to :)

Thanks for the review. Obviously, that's called catch_ because catch is a
keyword. Good news is I think I can get rid of it altogether, and match
exceptions based on a handler taking an argument of a type that derives
from std::exception. So, instead of:

leaf::try_catch(
  []
  {
    ....
  },
  []( catch_<my_exception>, .... )
  {
  } );

You'd just say:

leaf::try_catch(
  []
  {
    ....
  },
  []( my_exception &, .... )
  {
  } );

OTOH, catch_ can be given multiple exception types, and it'll match if the
caught exception is of any one of the specified types.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk