separateIor

fun <A, B> Iterable<Ior<A, B>>.separateIor(): Pair<List<A>, List<B>>

splits a union into its component parts.

fun test() {
   listOf(
     Pair("A", 1).bothIor(),
     Pair("B", 2).bothIor(),
     "C".leftIor()
   ).separateIor() shouldBe Pair(listOf("A", "B", "C"), listOf(1, 2))
}