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 Alternative instance for Observable #723

Merged
merged 1 commit into from Sep 14, 2018

Conversation

Projects
None yet
2 participants
@jferris
Contributor

jferris commented Sep 14, 2018

There are instances for Applicative and MonoidK, but not for Alternative. Observable already implements all the necessary abstract methods and follows the Alternative laws.

This adds Alternative to Observable.CatsInstances so that Alternative methods like guard can be used. It's also more convenient as an implicit dependency than MonoidK with Applicative.

Resolves #722.

Add Alternative instance for Observable
There are instances for Applicative and MonoidK, but not for
Alternative. Observable already implements all the necessary abstract
methods and follows the Alternative laws.

This adds Alternative to Observable.CatsInstances so that Alternative
methods like `guard` can be used. It's also more convenient as an
implicit dependency than `MonoidK with Applicative`.
@alexandru

If it passes the tests, it goes.

@codecov

This comment has been minimized.

codecov bot commented Sep 14, 2018

Codecov Report

Merging #723 into master will decrease coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master     #723      +/-   ##
==========================================
- Coverage   90.65%   90.63%   -0.02%     
==========================================
  Files         392      392              
  Lines       11013    11013              
  Branches     2080     2080              
==========================================
- Hits         9984     9982       -2     
- Misses       1029     1031       +2

@alexandru alexandru merged commit 044c4b8 into monix:master Sep 14, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment