typelevel/cats-effect

Add `Lock` to std

Open

#3.535 aberto em 15 de abr. de 2023

Ver no GitHub
 (6 comments) (2 reactions) (1 assignee)Scala (572 forks)batch import
:mushroom: enhancementgood first issue

Métricas do repositório

Stars
 (2.230 stars)
Métricas de merge de PR
 (Mesclagem média 21d 23h) (18 fundiu PRs em 30d)

Description

Spinning out of https://github.com/typelevel/cats-effect/pull/3480#discussion_r1125597170.

The API would look something like:

abstract class Lock[F[_]] {
  def shared: Resource[F, Unit]
  def exclusive: Resource[F, Unit]
}

Guia do colaborador