From 716109aa84ba3d5975b964351b6b0c5bec251ee5 Mon Sep 17 00:00:00 2001 From: YuitoSato Date: Sat, 9 Mar 2024 12:30:42 +0900 Subject: [PATCH] Return List of errors for all variants of zipOrAccumulate The four-arg and five-arg variants were returning Collection instead of List. --- .../commonMain/kotlin/com/github/michaelbull/result/Zip.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kotlin-result/src/commonMain/kotlin/com/github/michaelbull/result/Zip.kt b/kotlin-result/src/commonMain/kotlin/com/github/michaelbull/result/Zip.kt index 89a0dad..82b0b98 100644 --- a/kotlin-result/src/commonMain/kotlin/com/github/michaelbull/result/Zip.kt +++ b/kotlin-result/src/commonMain/kotlin/com/github/michaelbull/result/Zip.kt @@ -217,7 +217,7 @@ public inline fun zipOrAccumulate( producer3: () -> Result, producer4: () -> Result, transform: (T1, T2, T3, T4) -> V, -): Result> { +): Result> { contract { callsInPlace(producer1, InvocationKind.EXACTLY_ONCE) callsInPlace(producer2, InvocationKind.EXACTLY_ONCE) @@ -268,7 +268,7 @@ public inline fun zipOrAccumulate( producer4: () -> Result, producer5: () -> Result, transform: (T1, T2, T3, T4, T5) -> V, -): Result> { +): Result> { contract { callsInPlace(producer1, InvocationKind.EXACTLY_ONCE) callsInPlace(producer2, InvocationKind.EXACTLY_ONCE)