MergeableEither (original) (raw)
scala.util.Either.MergeableEither
Allows use of a merge
method to extract values from Either instances regardless of whether they are Left or Right.
val l = Left(List(1)): Either[List[Int], Vector[Int]]
val r = Right(Vector(1)): Either[List[Int], Vector[Int]]
l.merge: Seq[Int] // List(1)
r.merge: Seq[Int] // Vector(1)
Attributes
Source
Graph
Supertypes
Members list
Value members
Concrete methods
In this article
Generated with
Copyright (c) 2002-2025, LAMP/EPFL
Copyright (c) 2002-2025, LAMP/EPFL