
11 Sep
2008
11 Sep
'08
3:41 p.m.
On Thu, Sep 11, 2008 at 4:02 PM, Bruno Lalande <bruno.lalande@gmail.com> wrote:
Hello,
I've been using this compiler a few years ago and I remember it wasn't possible to write a function that only throws an exception without having a warning complaining that the function never returns. Basically, the compiler seemed to "ignore" the fact that a throw is supposed to return. It might be the reason of your error. My workaround used to be to put a dummy return statement just after the throw...
if this is the reason, then using the BOOST_UNREACHABLE_RETURN(result) macro is (AFAICT) the best option as some other compilers complain about returns (or any other code) behind unconditional throw being unreachable. Best ________________ ::matus_chochlik