|
Boost : |
Subject: Re: [boost] [Stacktrace] review
From: Emil Dotchevski (emildotchevski_at_[hidden])
Date: 2016-12-16 16:18:12
On Fri, Dec 16, 2016 at 11:05 AM, Niall Douglas <s_sourceforge_at_[hidden]>
wrote:
> On 15 Dec 2016 at 16:00, Emil Dotchevski wrote:
>
> > Do you mean a run-time hook or a compile-time hook?
> >
> > I think this should be compile-time hook in order to avoid the perils of
> > dynamic initialization in complex multi-thread programs. But we already
> > have that compile-time hook, it's called boost::throw_exception.
>
> Firstly thanks to all for the detailed discussion. Bringing it back
> to the review of Stacktrace which this is (and not of Exception,
> another discussion thread would suit that), I am seeing the following
> options proposed for Stacktrace:
>
> Option 1: That Stacktrace implement a macro like
> BOOST_STACKTRACE_THROW_EXCEPTION() which reimplements
> BOOST_THROW_EXCEPTION() but with muxed in stacktrace.
>
> Option 2: That Stacktrace optionally hook some compile time hook in
> Boost.Exception to mux in stacktrace.
>
> Option 3: That Stacktrace optionally hook some runtime hook in
> Boost.Exception to mux in stacktrace.
>
>
> Implied in all the above is that the exception type stacktrace mux in
> framework as described in the current Stacktrace docs is considered
> bad form and should be deleted?
>
> Can people interested vote on one of the options above, or propose
> their own option, and say whether they want the documented mux in
> mechanism removed or not?
>
It seems that there is some disagreement on how costly each of the options
is. I think that before a vote we should look at actual code, actual
proposed changes, and actual costs in terms of coupling and speed/space.
This shouldn't be difficult to do, given that Stacktrace already exists.
Emil
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk