Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[DI] turn $private to protected in dumped container, to make cache:clear BC #25268

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 4, 2017

Conversation

nicolas-grekas
Copy link
Member

@nicolas-grekas nicolas-grekas commented Dec 2, 2017

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

Turning this property to protected changes nothing to its visibility in practice as the class is final anyway,
but when migrating to SF4.0 from 3.4, the cache:clear command chokes with "Compile Error: Access level to srcDevDebugProjectContainer::$privates must be protected".

Let's make it protected to remove this WTF.

@@ -874,7 +874,7 @@ class $class extends $baseClass
{
private \$parameters;
private \$targetDirs = array();
private \$privates = array();
protected \$privates = array();
Copy link
Member

Choose a reason for hiding this comment

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

A small comment should be added to explain why this specific one is not private.

@nicolas-grekas nicolas-grekas changed the title [DI] turn $private to protected in dumped container, to make cache:cl… [DI] turn $private to protected in dumped container, to make cache:clear BC Dec 3, 2017
@nicolas-grekas
Copy link
Member Author

Comment added.

Status: needs review

@nicolas-grekas nicolas-grekas changed the base branch from master to 4.0 December 3, 2017 13:22
@fabpot
Copy link
Member

fabpot commented Dec 4, 2017

Thank you @nicolas-grekas.

@fabpot fabpot merged commit c98d967 into symfony:4.0 Dec 4, 2017
fabpot added a commit that referenced this pull request Dec 4, 2017
…ke cache:clear BC (nicolas-grekas)

This PR was merged into the 4.0 branch.

Discussion
----------

[DI] turn $private to protected in dumped container, to make cache:clear BC

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

Turning this property to protected changes nothing to its visibility in practice as the class is final anyway,
but when migrating to SF4.0 from 3.4, the `cache:clear` command chokes with "Compile Error: Access level to srcDevDebugProjectContainer::$privates must be protected".

Let's make it protected to remove this WTF.

Commits
-------

c98d967 [DI] turn $private to protected in dumped container, to make cache:clear BC
@fabpot fabpot mentioned this pull request Dec 5, 2017
@nicolas-grekas nicolas-grekas deleted the di-protected-privates branch December 5, 2017 07:47
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.

7 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.