Bernhard
09/26/2019, 3:38 PMCasey Brooks
09/26/2019, 3:44 PMEither
https://arrow-kt.io/docs/arrow/core/either/ which do not introduce ambiguity to the type systemCasey Brooks
09/26/2019, 3:46 PMdynamic
type already for cases where JS objects have that union type, and you can cast/convert that to the Kotlin type as appropriatestreetsofboston
09/26/2019, 3:46 PMEither
from Arrow.Bernhard
09/26/2019, 3:46 PMstreetsofboston
09/26/2019, 3:47 PMEither<Int, String>
or something.Bernhard
09/26/2019, 3:47 PMBernhard
09/26/2019, 3:48 PMstreetsofboston
09/26/2019, 3:49 PMsealed class Either<out L, out R>
class Left<out L>(val left: L) : Either<L, Nothing>() { ... }
class Right<out R>(val right: R): Either<Nothing, R> { ... }
And add some extension functions to ‘map’, ‘flatMap’, etc.GarouDan
09/26/2019, 3:53 PMPaul Woitaschek
09/26/2019, 4:09 PMPaul Woitaschek
09/26/2019, 4:09 PMkarelpeeters
09/26/2019, 4:28 PMyen
09/28/2019, 8:48 AMkarelpeeters
09/28/2019, 9:12 AMraulraja
11/03/2019, 11:40 PM