Skip to content

Commit

Permalink
Update scaladoc.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kamil Kloch committed Nov 13, 2024
1 parent b05f7fc commit 9cd6897
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,16 +44,17 @@ private[std] trait DispatcherPlatform[F[_]] { this: Dispatcher[F] =>
}

/**
* Submits an effect to be executed and indefinitely blocks until a result is produced. This
* function will throw an exception if the submitted effect terminates with an error.
* Submits an effect to be executed and indefinitely blocks until a result is produced.
* Cancels the effect in case of Java thread interruption. This function will throw an
* exception if the submitted effect terminates with an error.
*/
def unsafeRunSync[A](fa: F[A]): A =
unsafeRunTimed(fa, Duration.Inf)

/**
* Submits an effect to be executed and blocks for at most the specified timeout for a result
* to be produced. This function will throw an exception if the submitted effect terminates
* with an error.
* to be produced. Cancels the effect both in case of timeout or Java thread interruption.
* This function will throw an exception if the submitted effect terminates with an error.
*/
def unsafeRunTimed[A](fa: F[A], timeout: Duration): A = {
val (fut, cancel) = unsafeToFutureCancelable(fa)
Expand Down

0 comments on commit 9cd6897

Please sign in to comment.