Skip to content

array_filter w/ arrow functions return type extension#402

Merged
ondrejmirtes merged 2 commits intophpstan:masterfrom
b1rdex:array-filter-array-function
Dec 22, 2020
Merged

array_filter w/ arrow functions return type extension#402
ondrejmirtes merged 2 commits intophpstan:masterfrom
b1rdex:array-filter-array-function

Conversation

@b1rdex
Copy link
Contributor

@b1rdex b1rdex commented Dec 8, 2020

Copy link
Member

@ondrejmirtes ondrejmirtes left a comment

Choose a reason for hiding this comment

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

  1. Please fix the build.
  2. Please add an actual test for the rule that flags the code as errorneous in phpstan/phpstan#4188, thanks.

@ondrejmirtes ondrejmirtes force-pushed the master branch 3 times, most recently from d45166a to 3526237 Compare December 12, 2020 10:56
@b1rdex b1rdex force-pushed the array-filter-array-function branch 2 times, most recently from bc1845c to c978ac7 Compare December 22, 2020 08:41
@b1rdex b1rdex force-pushed the array-filter-array-function branch from c978ac7 to 31f9e08 Compare December 22, 2020 09:07
@ondrejmirtes
Copy link
Member

FYI you can also run tests locally, simply run vendor/bin/phing tests-fast :) And I still need the regression test for the actual error message from phpstan/phpstan#4188. Probably in CallMethodsRuleTest.

@b1rdex
Copy link
Contributor Author

b1rdex commented Dec 22, 2020

@ondrejmirtes I added another test. I don't know why, but it fails with Call to method onlyB() on an unknown class Bug4188\Test. I can't find any way to solve it.

@ondrejmirtes
Copy link
Member

You need to run composer dump-autoload, then run the test.

@ondrejmirtes ondrejmirtes merged commit 0af0399 into phpstan:master Dec 22, 2020
@ondrejmirtes
Copy link
Member

Thank you!

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.

array_filter works different when short function syntax used

2 participants