Skip to content

Add PrivatizeLocalClassConstantRector to SOLID#1333

Merged
TomasVotruba merged 1 commit intorectorphp:masterfrom
mxr576:add_missing_solid_rector
Apr 23, 2019
Merged

Add PrivatizeLocalClassConstantRector to SOLID#1333
TomasVotruba merged 1 commit intorectorphp:masterfrom
mxr576:add_missing_solid_rector

Conversation

@mxr576
Copy link
Copy Markdown
Contributor

@mxr576 mxr576 commented Apr 23, 2019

Original PR: #1304

@mxr576
Copy link
Copy Markdown
Contributor Author

mxr576 commented Apr 23, 2019

@TomasVotruba Although I am not sure what is the minimum required PHP version by the SOLID config set. I saw an "Add PHP 7.1 level min" task in the original PR and adding visibility to constants is only supported in >= PHP 7.1.

https://www.php.net/manual/en/language.oop5.constants.php

@TomasVotruba
Copy link
Copy Markdown
Member

The PHP version is checked inside the rule:

if (! $this->isAtLeastPhpVersion('7.1')) {
return null;
}

@TomasVotruba
Copy link
Copy Markdown
Member

Thank you for PR!

@TomasVotruba TomasVotruba merged commit 8c7dc0f into rectorphp:master Apr 23, 2019
TomasVotruba added a commit that referenced this pull request Nov 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants