Skip to content
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

Elaborate on Foldable#collectFirst comment #2278

Merged
merged 2 commits into from
Jun 11, 2018
Merged

Elaborate on Foldable#collectFirst comment #2278

merged 2 commits into from
Jun 11, 2018

Conversation

kubukoz
Copy link
Member

@kubukoz kubukoz commented Jun 3, 2018

btw. would it make sense to say more about the trick used?

@johnynek
Copy link
Contributor

johnynek commented Jun 4, 2018

it would make sense to add to the comment, which is a general trick to avoid calling both isDefined and apply, but also to avoid using lift.

@kubukoz kubukoz changed the title Fix typo in Foldable comment Elaborate on Foldable#collectFirst comment Jun 5, 2018
@kubukoz
Copy link
Member Author

kubukoz commented Jun 5, 2018

I'll add a mention of that.

@codecov-io
Copy link

codecov-io commented Jun 10, 2018

Codecov Report

Merging #2278 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2278   +/-   ##
=======================================
  Coverage   94.97%   94.97%           
=======================================
  Files         337      337           
  Lines        5832     5832           
  Branches      217      217           
=======================================
  Hits         5539     5539           
  Misses        293      293
Impacted Files Coverage Δ
core/src/main/scala/cats/Foldable.scala 100% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3993dba...220190b. Read the comment docs.

@kubukoz
Copy link
Member Author

kubukoz commented Jun 10, 2018

Finally found a moment to add more info, please review

Copy link
Contributor

@ceedubs ceedubs left a comment

Choose a reason for hiding this comment

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

Thanks @kubukoz! This trick is new to me, so I definitely appreciate the explanation :)

@johnynek
Copy link
Contributor

👍

@kubukoz
Copy link
Member Author

kubukoz commented Jun 11, 2018

:shipit:

@kailuowang kailuowang merged commit 1d7ee78 into typelevel:master Jun 11, 2018
@kailuowang kailuowang added this to the 1.2 milestone Jun 11, 2018
@kubukoz kubukoz deleted the fix-collectFirst-typo branch June 11, 2018 17:06
eli-jordan pushed a commit to eli-jordan/cats that referenced this pull request Jun 16, 2018
* Fix typo in Foldable comment

* Update Foldable.scala
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants