KC

Size: a a a
KC
NV
NV
ᛒ
ΛВ
KC
NV
NV
trait MonadCancel[F[_], E] extends MonadError[F, E]
Oℕ
NV
trait MonadError[F[_], E] extends ApplicativeError[F, E] with Monad[F] {
trait MonadCancel[F[_], E] extends MonadError[F, E] {
// analogous to productR, except discarding short-circuiting (and optionally some effect contexts) except for cancelation
def forceR[A, B](fa: F[A])(fb: F[B]): F[B]
def uncancelable[A](body: Poll[F] => F[A]): F[A]
// produces an effect which is already canceled (and doesn't introduce an async boundary)
// this is effectively a way for a fiber to commit suicide and yield back to its parent
// The fallback (unit) value is produced if the effect is sequenced into a block in which
// cancelation is suppressed.
def canceled: F[Unit]
def onCancel[A](fa: F[A], fin: F[Unit]): F[A]
NV
trait GenConcurrent[F[_], E] extends GenSpawn[F, E] {
import GenConcurrent._
def ref[A](a: A): F[Ref[F, A]]
def deferred[A]: F[Deferred[F, A]]
NV
trait GenSpawn[F[_], E] extends MonadCancel[F, E] {
def start[A](fa: F[A]): F[Fiber[F, E, A]]
// produces an effect which never returns
def never[A]: F[A]
// introduces a fairness boundary by yielding control to the underlying dispatcher
def cede: F[Unit]
NV
trait GenTemporal[F[_], E] extends GenConcurrent[F, E] with Clock[F] {
// (sleep(n) *> now) <-> now.map(_ + n + d) forSome { val d: Double }
def sleep(time: FiniteDuration): F[Unit]
w
trait MonadError[F[_], E] extends ApplicativeError[F, E] with Monad[F] {
trait MonadCancel[F[_], E] extends MonadError[F, E] {
// analogous to productR, except discarding short-circuiting (and optionally some effect contexts) except for cancelation
def forceR[A, B](fa: F[A])(fb: F[B]): F[B]
def uncancelable[A](body: Poll[F] => F[A]): F[A]
// produces an effect which is already canceled (and doesn't introduce an async boundary)
// this is effectively a way for a fiber to commit suicide and yield back to its parent
// The fallback (unit) value is produced if the effect is sequenced into a block in which
// cancelation is suppressed.
def canceled: F[Unit]
def onCancel[A](fa: F[A], fin: F[Unit]): F[A]
w
trait MonadError[F[_], E] extends ApplicativeError[F, E] with Monad[F] {
trait MonadCancel[F[_], E] extends MonadError[F, E] {
// analogous to productR, except discarding short-circuiting (and optionally some effect contexts) except for cancelation
def forceR[A, B](fa: F[A])(fb: F[B]): F[B]
def uncancelable[A](body: Poll[F] => F[A]): F[A]
// produces an effect which is already canceled (and doesn't introduce an async boundary)
// this is effectively a way for a fiber to commit suicide and yield back to its parent
// The fallback (unit) value is produced if the effect is sequenced into a block in which
// cancelation is suppressed.
def canceled: F[Unit]
def onCancel[A](fa: F[A], fin: F[Unit]): F[A]
NV
R
trait MonadError[F[_], E] extends ApplicativeError[F, E] with Monad[F] {
trait MonadCancel[F[_], E] extends MonadError[F, E] {
// analogous to productR, except discarding short-circuiting (and optionally some effect contexts) except for cancelation
def forceR[A, B](fa: F[A])(fb: F[B]): F[B]
def uncancelable[A](body: Poll[F] => F[A]): F[A]
// produces an effect which is already canceled (and doesn't introduce an async boundary)
// this is effectively a way for a fiber to commit suicide and yield back to its parent
// The fallback (unit) value is produced if the effect is sequenced into a block in which
// cancelation is suppressed.
def canceled: F[Unit]
def onCancel[A](fa: F[A], fin: F[Unit]): F[A]
NV
R
λ