Re: Using zip to copy subarray into another

2013-08-14 Thread Craig Dillabaugh
On Tuesday, 13 August 2013 at 21:37:28 UTC, Joseph Rushton Wakeling wrote: clip. Try lockstep instead of zip. See: http://d.puremagic.com/issues/show_bug.cgi?id=8155#c8 ... for more info on the reasons why zip doesn't work here. While I've now solved my problem using a slightly different met

Re: Using zip to copy subarray into another

2013-08-14 Thread Craig Dillabaugh
On Tuesday, 13 August 2013 at 21:10:53 UTC, John Colvin wrote: On Tuesday, 13 August 2013 at 20:23:00 UTC, Craig Dillabaugh wrote: On Tuesday, 13 August 2013 at 19:50:37 UTC, Jonathan M Davis wrote: On Tuesday, August 13, 2013 21:22:24 Craig Dillabaugh wrote: I have code that attempts to copy

Re: Using zip to copy subarray into another

2013-08-13 Thread Joseph Rushton Wakeling
On 08/13/2013 09:22 PM, Craig Dillabaugh wrote: > I have code that attempts to copy a slice of one array into > another using zip. However, the array is not updated. I am > guessing this is because modifying the returned tuple does not > modify the actual arrays. > > Is there any way to do this.

Re: Using zip to copy subarray into another

2013-08-13 Thread John Colvin
On Tuesday, 13 August 2013 at 20:23:00 UTC, Craig Dillabaugh wrote: On Tuesday, 13 August 2013 at 19:50:37 UTC, Jonathan M Davis wrote: On Tuesday, August 13, 2013 21:22:24 Craig Dillabaugh wrote: I have code that attempts to copy a slice of one array into another using zip. However, the array

Re: Using zip to copy subarray into another

2013-08-13 Thread Craig Dillabaugh
On Tuesday, 13 August 2013 at 19:50:37 UTC, Jonathan M Davis wrote: On Tuesday, August 13, 2013 21:22:24 Craig Dillabaugh wrote: I have code that attempts to copy a slice of one array into another using zip. However, the array is not updated. I am guessing this is because modifying the returned

Re: Using zip to copy subarray into another

2013-08-13 Thread Jonathan M Davis
On Tuesday, August 13, 2013 21:22:24 Craig Dillabaugh wrote: > I have code that attempts to copy a slice of one array into > another using zip. However, the array is not updated. I am > guessing this is because modifying the returned tuple does not > modify the actual arrays. > > Is there any way

Using zip to copy subarray into another

2013-08-13 Thread Craig Dillabaugh
I have code that attempts to copy a slice of one array into another using zip. However, the array is not updated. I am guessing this is because modifying the returned tuple does not modify the actual arrays. Is there any way to do this. import std.stdio; import std.range; void main( string[]