Peter,
On 25/04/11 10:22, [email protected] wrote:
1. Calling R_CheckUserInterrupt() interrupts immediately, so I have no
possibility to exit my code gracefully. In particular, I suppose that
objects created on the heap (e.g., STL containers) are not destructed
properly.
Sorry not to have seen this thread sooner.
You may like to give CXXR a try
(http://www.cs.kent.ac.uk/projects/cxxr/). In CXXR the R interpreter is
written in C++, and a user interrupt is handled by throwing a C++
exception, so the stack is unwound in an orderly fashion, destructors
are invoked, etc.
However, it's fair to say that in using CXXR with a multi-threaded
program you'll be on the bleeding edge...
Andrew
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel