typelevel / typelevel/cats

Standardize & document cats' stance on currying

Open
#147 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

meta
Dominant language
Scala
Stars
5.5k
Forks
1.2k
Avg merge
2d 10h
Merged PRs (30d)
5

Description

As of c675ee3da29b60da578eeb03cfd289c19cbbd8b0, we have a mix of currying styles for methods that take 2+ functions.

Invariant (imap) and Profunctor (dimap) pass each function in its own argument list whereas Bifunctor (bimap), Kleisli (dimap), and Cokleisli (dimap) pass both functions in the same argument list.

Let's pick a style and make it consistent throughout.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by inspecting the implementations of Invariant.imap, Profunctor.dimap, Bifunctor.bimap, Kleisli.dimap, and Cokleisli.dimap mentioned in the issue. Compare their argument-list conventions, determine the consistent stance to adopt, update the affected APIs, and run the project's test suite to verify the standardized behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
backend-api-design
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.