This is great, thanks! I verified pointer(X) is the same as what pointer(x_next) used to be before running your line of code, and pointer(x_next) after running your line of code is the same as pointer(x).
I did not know of this about Julia! On Saturday, 4 October 2014 11:05:33 UTC-4, David P. Sanders wrote: > > Hi, > > Are you sure that you need a copy operation? If I understand correctly > what you are doing, you just need access to the x from the previous > iteration. > > Could you not just swap x and x_next and avoid the copy : > > X, x_next = x_next, x > > (so you create them once only). > >
