You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To maintain binary compatibility we can't add new methods with default implementation to existing traits. However we can add new traits with those and have classes extending them.
For example, we want to add a new method to a Typeclass TC[F[_]]. we could either provide a syntax trait that provides that method like
If this new method cannot be provided as a syntax to the data types we can add an implicit class against the Typeclass itself.
In both case, we can't have any existing trait extend these new trait. We would need to have several objects in cats inherit this new trait explicitly including cats.implicitscats.syntax.all, etc.
We should decide on a strategy and document in guideline.
The text was updated successfully, but these errors were encountered:
To maintain binary compatibility we can't add new methods with default implementation to existing traits. However we can add new traits with those and have classes extending them.
For example, we want to add a new method to a Typeclass TC[F[_]]. we could either provide a syntax trait that provides that method like
If this new method cannot be provided as a syntax to the data types we can add an implicit class against the Typeclass itself.
In both case, we can't have any existing trait extend these new trait. We would need to have several objects in cats inherit this new trait explicitly including
cats.implicits
cats.syntax.all
, etc.We should decide on a strategy and document in guideline.
The text was updated successfully, but these errors were encountered: