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

Introduce isLeft & isRight predicate API for Either #2927

Merged
merged 7 commits into from
Feb 9, 2023

Conversation

nomisRev
Copy link
Member

@nomisRev nomisRev commented Feb 9, 2023

In an interesting #2913 (comment) between myself, @myuwono and @franciscodr in Option API deprecation we came up with a set of new operators to replace exists in a new meaningful API that we thought was very Kotlin idiomatic.

This PR adds the relevant APIs for Either.

@nomisRev nomisRev requested review from serras, raulraja, franciscodr, myuwono and a team February 9, 2023 09:43
@nomisRev nomisRev added the 1.2.0 Tickets belonging to 1.1.2 label Feb 9, 2023
@nomisRev nomisRev changed the title Sv is xxx either predicate Introduce isLeft & isRight predicate API for Either Feb 9, 2023
Copy link
Collaborator

@franciscodr franciscodr left a comment

Choose a reason for hiding this comment

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

Thanks, @nomisRev!

@github-actions
Copy link
Contributor

github-actions bot commented Feb 9, 2023

Kover Report

File Coverage [58.42%]
arrow-libs/core/arrow-core/src/commonMain/kotlin/arrow/core/Either.kt 58.42%
Total Project Coverage 43.62%

Copy link
Member

@i-walker i-walker left a comment

Choose a reason for hiding this comment

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

🙌🏾 Nice

@serras
Copy link
Member

serras commented Feb 9, 2023

I really like this API design :)

Copy link
Collaborator

@myuwono myuwono left a comment

Choose a reason for hiding this comment

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

Thank you @nomisRev this is really awesome!

@nomisRev nomisRev merged commit c5717cc into main Feb 9, 2023
@nomisRev nomisRev deleted the sv-isXXX-either-predicate branch February 9, 2023 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.2.0 Tickets belonging to 1.1.2
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants