given_Functor_Option

given given_Functor_Option: Functor[[A] =>> Option[A]]

Value members

Concrete methods

def fmap[A, B](f: A => B): Option[A] => Option[B]

Extensions

Inherited extensions

extension (fa: F[A])
@targetName("voidLeft")
def $>[A, B](a: B): Option[B]

Drop whatever value A on left and return F[B] on the right

Drop whatever value A on left and return F[B] on the right

Example
Option(1) `$>` 3 == Option(3)
Inherited from
Functor
@targetName("mapFlipped")
def <#>[A, B](f: A => B): Option[B]

Usually fmap takes function first, mapFlipped takes data first

Usually fmap takes function first, mapFlipped takes data first

Example
fa <#> identity == identity(fa)
Inherited from
Functor
def map[A, B](f: A => B): Option[B]
Inherited from
Functor
def void[A, B]: Option[Unit]

Void F[A] and return F[Unit]

Void F[A] and return F[Unit]

Example
Option(2).void == Option(())
Inherited from
Functor