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

Add leftTraverse and leftSequence to Bitraverse typeclass #2646

Closed
wants to merge 1 commit into from

Conversation

ikempf
Copy link

@ikempf ikempf commented Nov 28, 2018

Bitraverse should offer "left" traversing functionality.
Right-traversal is already offered through Traverse typeclass, bi-traversal and left-traversal should both be offered by Bitraverse. This keeps it consistent with Bifunctor (which offers leftMap).

This resolves issue #2474

@kailuowang
Copy link
Contributor

Unfortunately we can't add methods to traits without breaking binary compatibility on Scala 2.11.
You can add this to a new syntax extension trait like in #2588.

@ikempf ikempf changed the title Add leftTraverse to Bitraverse typeclass Add leftTraverse and leftSequence to Bitraverse typeclass Nov 28, 2018
@ikempf
Copy link
Author

ikempf commented Nov 28, 2018

I removed methods from existing traits (Bitraverse and BitraverseSyntax) and moved everything into a new trait BitraverseSyntaxBinCompat0 that is extended by AllSyntaxBinCompat3 and bitraverse.

@LukaJCB
Copy link
Member

LukaJCB commented Nov 29, 2018

Seems like this is a duplicate of #2606

@ikempf
Copy link
Author

ikempf commented Nov 30, 2018

@LukaJCB You are right it is a duplicate

@ikempf ikempf closed this Nov 30, 2018
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.

3 participants