Hoogle Search

Within LTS Haskell 24.52 (ghc-9.10.3)

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

  1. isAlreadyInUseError :: IOError -> Bool

    classy-prelude ClassyPrelude

    An error indicating that an IO operation failed because one of its arguments is a single-use resource, which is already being used (for example, opening the same file twice for writing might give this error).

  2. isAlreadyInUseErrorType :: IOErrorType -> Bool

    classy-prelude ClassyPrelude

    I/O error where the operation failed because one of its arguments is a single-use resource, which is already being used.

  3. runReaderT :: ReaderT r (m :: Type -> Type) a -> r -> m a

    classy-prelude ClassyPrelude

    No documentation available.

  4. yieldThread :: MonadIO m => m ()

    classy-prelude ClassyPrelude

    Originally yield.

  5. threadId :: NotFoundException -> ThreadId

    context Context

    No documentation available.

  6. data ThreadId

    context Context.Concurrent

    A ThreadId is an abstract type representing a handle to a thread. ThreadId is an instance of Eq, Ord and Show, where the Ord instance implements an arbitrary total ordering over ThreadIds. The Show instance lets you convert an arbitrary-valued ThreadId to string form; showing a ThreadId value is occasionally useful when debugging or diagnosing the behaviour of a concurrent program. Note: in GHC, if you have a ThreadId, you essentially have a pointer to the thread itself. This means the thread itself can't be garbage collected until you drop the ThreadId. This misfeature would be difficult to correct while continuing to support threadStatus.

  7. isCurrentThreadBound :: IO Bool

    context Context.Concurrent

    Returns True if the calling thread is bound, that is, if it is safe to use foreign libraries that rely on thread-local state from the calling thread.

  8. killThread :: ThreadId -> IO ()

    context Context.Concurrent

    killThread raises the ThreadKilled exception in the given thread (GHC only).

    killThread tid = throwTo tid ThreadKilled
    

  9. mkWeakThreadId :: ThreadId -> IO (Weak ThreadId)

    context Context.Concurrent

    Make a weak pointer to a ThreadId. It can be important to do this if you want to hold a reference to a ThreadId while still allowing the thread to receive the BlockedIndefinitely family of exceptions (e.g. BlockedIndefinitelyOnMVar). Holding a normal ThreadId reference will prevent the delivery of BlockedIndefinitely exceptions because the reference could be used as the target of throwTo at any time, which would unblock the thread. Holding a Weak ThreadId, on the other hand, will not prevent the thread from receiving BlockedIndefinitely exceptions. It is still possible to throw an exception to a Weak ThreadId, but the caller must use deRefWeak first to determine whether the thread still exists.

  10. myThreadId :: IO ThreadId

    context Context.Concurrent

    Returns the ThreadId of the calling thread (GHC only).

Page 557 of many | Previous | Next