ref: 4a43da4f0216e079d71557a256a771f10b4dfd69
dir: /lib/Data/Either.hs/
-- Copyright 2023 Lennart Augustsson
-- See LICENSE file for full license.
module Data.Either(module Data.Either) where
data Either a b = Left a | Right b
either :: forall a b r . (a -> r) -> (b -> r) -> Either a b -> r
either fa fb arg =
case arg of
Left a -> fa a
Right b -> fb b