File tree 1 file changed +1
-7
lines changed
1 file changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -28,14 +28,12 @@ protected function doClone(mixed $var): array
28
28
$ objRefs = []; // Map of original object handles to their stub object counterpart
29
29
$ objects = []; // Keep a ref to objects to ensure their handle cannot be reused while cloning
30
30
$ resRefs = []; // Map of original resource handles to their stub object counterpart
31
- $ values = []; // Map of stub objects' ids to original values
32
31
$ maxItems = $ this ->maxItems ;
33
32
$ maxString = $ this ->maxString ;
34
33
$ minDepth = $ this ->minDepth ;
35
34
$ currentDepth = 0 ; // Current tree depth
36
35
$ currentDepthFinalIndex = 0 ; // Final $queue index for current tree depth
37
36
$ minimumDepthReached = 0 === $ minDepth ; // Becomes true when minimum tree depth has been reached
38
- $ cookie = (object ) []; // Unique object used to detect hard references
39
37
$ a = null ; // Array cast for nested structures
40
38
$ stub = null ; // Stub capturing the main properties of an original item value
41
39
// or null if the original value is used directly
@@ -53,7 +51,7 @@ protected function doClone(mixed $var): array
53
51
}
54
52
}
55
53
56
- $ refs = $ vals = $ queue [$ i ];
54
+ $ vals = $ queue [$ i ];
57
55
foreach ($ vals as $ k => $ v ) {
58
56
// $v is the original value or a stub object in case of hard references
59
57
@@ -215,10 +213,6 @@ protected function doClone(mixed $var): array
215
213
$ queue [$ i ] = $ vals ;
216
214
}
217
215
218
- foreach ($ values as $ h => $ v ) {
219
- $ hardRefs [$ h ] = $ v ;
220
- }
221
-
222
216
return $ queue ;
223
217
}
224
218
}
You can’t perform that action at this time.
0 commit comments