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
add PHPStan and fix found issues #157
Conversation
f2f0778
to
f5ff2ac
Compare
Good job. One thing is troubling me, it means that only nette/utils has defined propel phpDoc and other packages have not. Do you plan at it to the others, too? |
I don't see how that is relevant. It it forbidden to fix bug in one package without fixing bugs in all packages? |
Nope, don't get me wrong I like the change. /**
* Replaces or appends a item.
* @param int|null
* @return void
* @throws Nette\OutOfRangeException
*/
public function offsetSet($index, $value) => /**
* Replaces or appends a item.
* @param int|null $index
* @return void
* @throws Nette\OutOfRangeException
*/
public function offsetSet($index, $value) But, we should do it for all packages. To keep it same. I don't want to add phpdoc to one method and not to others, right? |
Great work. I merged most of issues 32fd477 I have not added PhpStan yet, I must first become familiar with it. Also I did not add the parameter $names in phpDoc because it is not used in another places. |
What places? You mean other |
Yes. |
@dg Well, we can't add this to all packages at once. One package will always need to be the first. Also we've already had a related discussion few years ago. |
Yes, RFC was accepted. |
8aa61b9
to
fd48510
Compare
@JanTvrdik how can be solved this error? https://travis-ci.org/nette/utils/jobs/361331623 |
Needs to be added to ignored errors: https://github.com/nette/utils/blob/master/phpstan.neon#L2 |
@dg Here are your options:
|
How can I fix PHP configuration on Travis? |
I don't think you can fix it, that's why I didn't suggest it. PHP must be compiled with WEBP support, but it obviously isn't on Travis. :/ |
No description provided.