Hoogle Search

Within LTS Haskell 24.45 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. newtype SemaphoreName

    semaphore-compat System.Semaphore

    No documentation available.

  2. SemaphoreName :: String -> SemaphoreName

    semaphore-compat System.Semaphore

    No documentation available.

  3. createSemaphore :: SemaphoreName -> Int -> IO Semaphore

    semaphore-compat System.Semaphore

    Create a new semaphore with the given name and initial amount of available resources. Throws an error if a semaphore by this name already exists.

  4. destroySemaphore :: Semaphore -> IO ()

    semaphore-compat System.Semaphore

    Destroy the given semaphore.

  5. forkWaitOnSemaphoreInterruptible :: Semaphore -> (Either SomeException Bool -> IO ()) -> IO WaitId

    semaphore-compat System.Semaphore

    Spawn a thread that waits on the given semaphore. In this thread, asynchronous exceptions will be masked. The waiting operation can be interrupted using the interruptWaitOnSemaphore function. This implements a similar pattern to the forkFinally function.

  6. freshSemaphore :: String -> Int -> IO Semaphore

    semaphore-compat System.Semaphore

    Create a fresh semaphore with the given amount of tokens. Its name will start with the given prefix, but will have a random suffix appended to it.

  7. getSemaphoreName :: SemaphoreName -> String

    semaphore-compat System.Semaphore

    No documentation available.

  8. getSemaphoreValue :: Semaphore -> IO Int

    semaphore-compat System.Semaphore

    Query the current semaphore value (how many tokens it has available). This is mainly for debugging use, as it is easy to introduce race conditions when nontrivial program logic depends on the value returned by this function.

  9. interruptWaitOnSemaphore :: WaitId -> IO ()

    semaphore-compat System.Semaphore

    Interrupt a semaphore wait operation initiated by forkWaitOnSemaphoreInterruptible.

  10. openSemaphore :: SemaphoreName -> IO Semaphore

    semaphore-compat System.Semaphore

    Open a semaphore with the given name. If no such semaphore exists, throws an error.

Page 1000 of many | Previous | Next