I think you can go with 

copy!(x, y)

Quoting the built-in help for reference:

help?> copy!
INFO: Loading help data...
Base.copy!(dest, src)

   Copy all elements from collection "src" to array "dest".
   Returns "dest".

Base.copy!(dest, do, src, so, N)

   Copy "N" elements from collection "src" starting at offset
   "so", to array "dest" starting at offset "do". Returns
   "dest".

On Monday, February 9, 2015 at 5:54:26 PM UTC-6, Kirill Ignatiev wrote:
>
> Given two Float64 arrays x and y of the same shape, is x[:]=y the correct 
> way to *efficiently* copy all values from one array into the other?
>
> Basically, I would like the equivalent of memcpy, just copying memory, and 
> doing no extra work.
>

Reply via email to