-
-
Notifications
You must be signed in to change notification settings - Fork 45
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
Update to Laminas Coding Standard 2.3 #99
Conversation
Signed-off-by: George Steel <george@net-glue.co.uk>
…mportInternalFunction Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
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.
Hmm, we'll need a 2.17.x
branch here, before merging
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
Signed-off-by: George Steel <george@net-glue.co.uk>
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.
LGTM, thanks @gsteel!
@@ -85,7 +83,7 @@ public function setFilterChain(FilterChain $filters) | |||
public function getFilterChain() | |||
{ | |||
if (null === $this->__filterChain) { | |||
$this->setFilterChain(new FilterChain()); | |||
$this->__filterChain = new FilterChain(); |
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.
Not much of a problem, but it may be possible that overrides to setFilterChain()
make this change a potential issue.
I'll let this one roll though, as it's really an edge case.
@@ -414,7 +429,7 @@ public function setFilterChain(FilterChain $filters) | |||
public function getFilterChain() | |||
{ | |||
if (null === $this->__filterChain) { | |||
$this->setFilterChain(new FilterChain()); | |||
$this->__filterChain = new FilterChain(); |
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.
Similar to above location: setter may have been overridden, although I'll let this one through.
Thanks @gsteel! |
Yeah, but I was waiting while I was generating an almost 40Gb performance profile for an app: https://twitter.com/Ocramius/status/1479844147427172360 :D |
Description
Updating and cleaning up for Laminas Coding Standard 2.3 including WIP on reducing Psalm Errors.
I appreciate that reviewing this is going to be hellish… FWIW, I'm pretty confident that there are no BC breaks but I have fixed some obvious errors in doc blocks.
The most notable changes are likely adding nullable type hints such as
function Foo(Type $baz = null)
changed tofunction Foo(?Type $baz = null)
.Also, there are a number of placeholder container/array access methods that had doc blocks for void return on methods such as
next()
that were returningparent::next()
- as these methods should have always been returning void anyhow, thereturn
statements have been dropped in these cases to satisfy CS.Please let me know if you'd like me to squash.
I also got a bit cavalier with the psalm baseline - I was left with around 130 new errors that all looked like the result of changing line numbers rather than new errors, so I just updated/added to the baseline - ~1000 psalm errors have been fixed in this pull so I decided to quit whilst I was ahead…