15

how can I re-throw an exception caught by

catch(...)

block?

MBZ
  • 26,084
  • 47
  • 114
  • 191

2 Answers2

29

throw with no operand rethrows the "current exception".

Steve Jessop
  • 273,490
  • 39
  • 460
  • 699
14

This is how.

catch(...)
{
    throw;
}
Drew Dormann
  • 59,987
  • 13
  • 123
  • 180
Manoj R
  • 3,197
  • 1
  • 21
  • 36