8000 [VarDumper] Remove unused code by wkania · Pull Request #60287 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[VarDumper] Remove unused code #60287

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 9, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
8000
Diff view
Diff view
8 changes: 1 addition & 7 deletions src/Symfony/Component/VarDumper/Cloner/VarCloner.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,12 @@ protected function doClone(mixed $var): array
$objRefs = []; // Map of original object handles to their stub object counterpart
$objects = []; // Keep a ref to objects to ensure their handle cannot be reused while cloning
$resRefs = []; // Map of original resource handles to their stub object counterpart
$values = []; // Map of stub objects' ids to original values
$maxItems = $this->maxItems;
$maxString = $this->maxString;
$minDepth = $this->minDepth;
$currentDepth = 0; // Current tree depth
$currentDepthFinalIndex = 0; // Final $queue index for current tree depth
$minimumDepthReached = 0 === $minDepth; // Becomes true when minimum tree depth has been reached
$cookie = (object) []; // Unique object used to detect hard references
$a = null; // Array cast for nested structures
$stub = null; // Stub capturing the main properties of an original item value
// or null if the original value is used directly
Expand All @@ -53,7 +51,7 @@ protected function doClone(mixed $var): array
}
}

$refs = $vals = $queue[$i];
$vals = $queue[$i];
foreach ($vals as $k => $v) {
// $v is the original value or a stub object in case of hard references

Expand Down Expand Up @@ -215,10 +213,6 @@ protected function doClone(mixed $var): array
$queue[$i] = $vals;
}

foreach ($values as $h => $v) {
$hardRefs[$h] = $v;
}

return $queue;
}
}
Loading
0