-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Changed private static array-properties to const #39959
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
Changed private static array-properties to const #39959
Conversation
a2cf584
to
7cd6f49
Compare
7cd6f49
to
aa79381
Compare
Can this change be automated? If not, then I'm likely 👎 |
I don't know of any tool providing this as an automation.
What do you exactly mean? Because of merge conflicts I offered to redo all the work on the next branches. I can prepare them already in advance. In a merge you can ignore all conflicts this branch creates. Similar to how fabpot did it with this PR #39775 (comment) In the previous PR everyone was generally 👍 for the change. As some time has passed and no one of the team did it I repeated the work (It's not that costly; took around 1,5 hours). |
Well, this can probably not be automated, because we cannot forbid using |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I forgot about this previous discussion.
Let's go.
Thank you @simonberger. |
Now merged up to 5.x. PR welcome for 5.1+ |
Looks like you solved all conflicts. Thank you. :) |
…simonberger) This PR was merged into the 5.1 branch. Discussion ---------- Changed private static array-properties to const (5.1) | Q | A | ------------- | --- | Branch? | 5.1 | Bug fix? | no | New feature? | no | Deprecations? | no | License | MIT This continues #39959 for 5.1 Just a few newly introduced readonly static array-properties. /cc @nicolas-grekas Commits ------- f891fb2 Changed private static array-properties to const static properties newly introduced in 5.1
…simonberger) This PR was merged into the 5.2 branch. Discussion ---------- Changed private static array-properties to const (5.2) | Q | A | ------------- | --- | Branch? | 5.2 | Bug fix? | no | New feature? | no | Deprecations? | no | License | MIT This continues #39959 for 5.2 Just two array-properties and a string property in one class newly added. /cc @nicolas-grekas Commits ------- a5fd0c4 Changed private static array-properties to const static properties newly introduced in 5.2
|
This changes all private static properties (just screened arrays) to private const. I left out those which have write access obviously and also those with
static::
access.It is a new implementation of #38213. Based on 4.4 this time.
If merging it up creates several conflicts, you could ignore all changes of 4.4 and I create a new branch for 5.1 or 5.2. I'll do this anyway if any new private static arrays are existing there.