Divisible extends upon Divide by providing an empty method called conquer. conquer is useful for proving identity laws when working with Divisible instances.

Extending the serializer example from Divide, conquer would simply serialize data to an empty string.

import arrow.Kind
import arrow.core.Tuple2
import arrow.core.toT
import com.example.domain.*

fun main(args: Array<String>) {
   val emptySerializer: SerializerOf<Int> = Serializer.divisible().conquer()

  val result = emptySerializer.fix().func(1)

Main Combinators


Constructs an empty value for any Kind<F, A>.


Arrow provides DivisibleLaws in the form of test cases for internal verification of lawful instances and third party apps creating their own Divisible instances.

See Deriving and creating custom typeclass to provide your own Divisible instances for custom datatypes.

Data types

Module Data types
arrow.core Const
arrow.mtl EitherT, Kleisli, OptionT, StateT, WriterT
arrow.typeclasses Conested
arrow.ui Sum

Type Class Hierarchy

Do you like Arrow?

Arrow Org