parallel icon indicating copy to clipboard operation
parallel copied to clipboard

Copy needs a context

Open krakjoe opened this issue 6 years ago • 2 comments
trafficstars

When parallel copies vars, it does so without a context, this means that if an array contains a reference to itself, overflow will result. I knew about this, and it didn't seem so urgent, however, since I added support for closure binding, this shortcoming can easily lead to overflow.

We must copy with a context, so that if a var is already copied for any particular context, it is not reduplicated, but subsequent copies refer to the already copied var.

I'll add a simple test case to reproduce the issue when I've got time to work on the solution.

Brought to my attention by: https://github.com/humbug/box/pull/429

krakjoe avatar Jun 13 '19 07:06 krakjoe

Any update on this? I would like to know if I can except it in a near future or if it's likely gonna wait another couple of month (it's mostly for myself to plan with some refactoring on Infection)

theofidry avatar Jul 18 '19 16:07 theofidry

It's hard to tell the difference between the near future, and a couple of months :)

I'm just not actually sure, it could be this weekend, or next, or in 5 ... it's going to take a whole weekend, that's for sure ...

krakjoe avatar Jul 19 '19 03:07 krakjoe

@realFlowControl I wrote the context stuff, but haven't done any tests, could you find some time to write some tests please? essentially anything with recursion ... I may find time, but it will likely be quicker if you do it ...

sorry about breaking CI ...

I think there's probably a few issues you can prune, and you are probably more familiar with what they are at this point than me ...

In case I didn't say it yet, thanks for all the effort :)

krakjoe avatar May 18 '24 06:05 krakjoe

I'm on a vacation with my family till Friday, but I'll I can pick up after my return.

In case I didn't say it yet, thanks for all the effort :)

❤️

realFlowControl avatar May 18 '24 07:05 realFlowControl

Enjoy your rest, I might get to it before then :)

krakjoe avatar May 18 '24 08:05 krakjoe