Skip to content

Propose Either.toTry(L => Throwable) #2734

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

Merged
merged 1 commit into from
Apr 20, 2023
Merged

Conversation

evantill
Copy link

@evantill evantill commented Feb 8, 2023

Add a method to convert an Either to a Try.

Example of the same approach in Scala : def toTry(implicit ev: <:<[A, Throwable]): Try[B]

@evantill evantill changed the title Add Try.of(Either) factory method (see #2653). Propose Either.toTry(L => Throwable) Feb 9, 2023
@evantill
Copy link
Author

evantill commented Feb 9, 2023

by coincidence this PR is the counterpart of PR #2724

@evantill
Copy link
Author

Hi, any update on this PR please ? You can close it if you are not interested by merging it

@danieldietrich
Copy link
Contributor

Hi, sorry for the late reply. This looks good to me.

Copy link
Contributor

@danieldietrich danieldietrich left a comment

Choose a reason for hiding this comment

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

LGTM

@danieldietrich danieldietrich merged commit d164913 into vavr-io:master Apr 20, 2023
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.

2 participants