Skip to content

Commit

Permalink
bug #24910 [HttpKernel][Debug] Remove noise from stack frames of depr…
Browse files Browse the repository at this point in the history
…ecations (nicolas-grekas)

This PR was merged into the 3.3 branch.

Discussion
----------

[HttpKernel][Debug] Remove noise from stack frames of deprecations

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #24625
| License       | MIT
| Doc PR        | -

Collecting arguments of deprecations is too heavy, and was unintended in fact.

Commits
-------

f154be3 [HttpKernel][Debug] Remove noise from stack frames of deprecations
  • Loading branch information
nicolas-grekas committed Nov 10, 2017
2 parents ead2a1a + f154be3 commit d4d8d3a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Symfony/Component/Debug/ErrorHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -707,7 +707,7 @@ private function cleanTrace($backtrace, $type, $file, $line, $throw)
}
if (!($throw || $this->scopedErrors & $type)) {
for ($i = 0; isset($lightTrace[$i]); ++$i) {
unset($lightTrace[$i]['args']);
unset($lightTrace[$i]['args'], $lightTrace[$i]['object']);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function configure(Event $event = null)
$handler->screamAt($levels);
}
if ($this->scope) {
$handler->scopeAt($this->levels);
$handler->scopeAt($levels & ~E_USER_DEPRECATED & ~E_DEPRECATED);
} else {
$handler->scopeAt(0, true);
}
Expand Down

0 comments on commit d4d8d3a

Please sign in to comment.