must .Call C functions return SEXP?
On Thu, Oct 28, 2010 at 10:59:26AM -0400, Simon Urbanek wrote:
Because R assumes that you don't mess with the arguments, it also optimizes b to point to the same object as a which you then modify.
I hope it sheds some light on it.
Indeed! Thank you Simon, that was a thorough and illuminating answer. (Now I have better understanding of how the machine works, and what the dangerous sharp bits are. :)
Andrew Piskorski <atp at piskorski.com> http://www.piskorski.com/