Boost logo

Boost Users :

Subject: Re: [Boost-users] [UTF] Let my debugger catch unhandled exceptions
From: Jeff Flinn (TriumphSprint2000_at_[hidden])
Date: 2010-04-26 07:50:41


Adam Nielsen wrote:
>> No. You can't tell UTF not to catch c++ exceptions.
>>
>> What you can do though is to run your test with log_level=message and see last
>> statement executed before the exception is thrown, set a break point there and
>> turn on 'catch throw' only after you've got to this point.
>
> Thanks for the suggestion. Unfortunately this only gives me the line number
> of the last BOOST_xxx macro executed, whereas the exception is thrown from
> deep within the code, long after the last BOOST_xxx macro has been used.
>
> It sounds like I might have to delve into the UTF source, perhaps if I can put
> an assert(false) when UTF handles an exception that might work, as assertion
> failures seem to be accessible through the debugger without any trouble.

What compiler are you using? MSVC has a setting that allows you to break
on exceptions at the point of throw. I usually put a break near the area
of concern, then set Break when an std::exception is thrown. I'm not
sure which other compiler/debuggers have this facility though.

Jeff


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net