Skip to content

[Cache] fix bad optim #29644

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
Dec 19, 2018
Merged

[Cache] fix bad optim #29644

merged 1 commit into from
Dec 19, 2018

Conversation

nicolas-grekas
Copy link
Member

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

@gerty3000
Copy link

@nicolas-grekas out of curiosity, could you provide a description why it fixes the thing?

@nicolas-grekas
Copy link
Member Author

@seclu see what @strider2038 provided in the linked issue #29643.


$e = new \Exception();
$this->includeHandler = function () use ($e) { throw $e; };
$this->includeHandler = function ($type, $msg, $file, $line) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't this be a static function?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it would be a public one - better not (and would be slower if that matters)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I meant a static anonymous function, i.e just adding static in front of the current function keyword, not moving it to a static method. It doesn't affect the visibility does it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

static it is now

@stof
Copy link
Member

stof commented Dec 18, 2018

@seclu it does not create an exception with its stack trace in the constructor anymore. the stack trace was the one retaining references to other stuff.

@nicolas-grekas nicolas-grekas merged commit b76d4ea into symfony:4.2 Dec 19, 2018
nicolas-grekas added a commit that referenced this pull request Dec 19, 2018
This PR was merged into the 4.2 branch.

Discussion
----------

[Cache] fix bad optim

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

Commits
-------

b76d4ea [Cache] fix bad optim
@fabpot fabpot mentioned this pull request Jan 6, 2019
@nicolas-grekas nicolas-grekas deleted the cache-fix branch January 25, 2019 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants