[Rcpp-devel] Rcpp::exception + threads = disaster
Joshua N Pritikin
jpritikin at pobox.com
Sat Feb 8 21:52:45 CET 2020
On Sat, Feb 08, 2020 at 03:47:49PM -0500, JJ Allaire wrote:
> On Sat, Feb 8, 2020 at 3:45 PM Joshua N Pritikin
> <[1]jpritikin at pobox.com> wrote:
> Sure, but does it *have* to be that way? It seems to me that
> exceptions.h line 40,
> rcpp_set_stack_trace(Shield<SEXP>(stack_trace()))
>
> Not sure about whether this is indeed a mandatory constraint (I didn't
> work on the stack trace bit).
If I'm reading it correctly, rcpp_set_stack_trace(Shield<SEXP>(stack_trace()))
will work equally well in either location. R can't introspect about
the C++ stack; It must be saving the R call stack.
More information about the Rcpp-devel
mailing list