[C++-sig] boost.python 2 exception handling

Andreas Kloeckner kloeckner at RTNA.DaimlerChrysler.COM
Mon Nov 4 19:52:41 CET 2002

Hi Dave,

On Sun, Nov 03, 2002 at 12:24:06PM -0500, David Abrahams wrote:
> Sorry it took me so long to respond. I've been travelling and many things
> got pushed back...

That's perfectly fine... I'm just glad I got help!

> Firstly, the warnings are caused by the fact that you're not building
> your extension module with Boost.Build... or more specifically, that
> you're putting boost in your #include path with -I instead of
> -isystem.  Well, in fairness we found that -isystem does weird things
> on some platforms so we had to use -I in those scenarios. You might be
> seeing that effect. I think the Boost.Preprocessor library also now
> has a fix which will prevent this warning from showing up, so you
> could try the latest Boost CVS instead if you like.

I'm not too concerned about the warnings, but thanks for the hint :)

> Hmm, I see you're using the "jam" command below. I'm not
> sure how that can work out; Boost.Build is designed to recognize
> whether you're invoking it as `jam' or `bjam' and to only use our
> Boost.Build behavior if it was `bjam'. 

I'm using a custom Jamfile - for various reasons beyond the scope of
this email. I might be missing some finer points of the build process,
but for right now, it does the job(tm). :)

> Secondly, I think you'll avoid the hard error if you use:
>    register_exception_translator<runtime_error>( &TranslateRTE );
> -------------------------------------------------^

That actually worked. If you have the time, it would be great if you
could explain the difference between passing a function with or without
the ampersand. As far as C++ was concerned, so far I thought the two
were perfectly equivalent...?

Thank you for your really great library and the great support :)


More information about the Cplusplus-sig mailing list