Skip to content

Commit

Permalink
Rename ConcurrencyError to AsyncError
Browse files Browse the repository at this point in the history
  • Loading branch information
propensive committed Dec 27, 2024
1 parent ffc4665 commit 63944a2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/core/turbulence-core.scala
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ extension [ElementType](stream: LazyList[ElementType])
def strict: LazyList[ElementType] = stream.length yet stream

def rate[DurationType: GenericDuration: SpecificDuration](duration: DurationType)
(using Monitor, Tactic[ConcurrencyError])
(using Monitor, Tactic[AsyncError])
: LazyList[ElementType] =

def recur(stream: LazyList[ElementType], last: Long): LazyList[ElementType] =
Expand Down Expand Up @@ -214,7 +214,7 @@ extension (obj: LazyList.type)
try
snooze(startTime + duration.milliseconds*iteration)
() #:: pulsar(duration)
catch case err: ConcurrencyError => LazyList()
catch case err: AsyncError => LazyList()

recur(0)

Expand Down
2 changes: 1 addition & 1 deletion src/core/turbulence.Pulsar.scala
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ class Pulsar[DurationType: GenericDuration](duration: DurationType):
if !continue then LazyList() else try
sleep(duration)
() #:: stream
catch case err: ConcurrencyError => LazyList()
catch case err: AsyncError => LazyList()

0 comments on commit 63944a2

Please sign in to comment.