Hoogle Search

Within LTS Haskell 24.38 (ghc-9.10.3)

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

  1. accursedUnutterablePerformIO :: IO a -> a

    bytestring Data.ByteString.Internal

    This "function" has a superficial similarity to unsafePerformIO but it is in fact a malevolent agent of chaos. It unpicks the seams of reality (and the IO monad) so that the normal rules no longer apply. It lulls you into thinking it is reasonable, but when you are not looking it stabs you in the back and aliases all of your mutable buffers. The carcass of many a seasoned Haskell programmer lie strewn at its feet. Witness the trail of destruction:

    Do not talk about "safe"! You do not know what is safe! Yield not to its blasphemous call! Flee traveller! Flee or you will be corrupted and devoured!

  2. deferForeignPtrAvailability :: ForeignPtr a -> IO (ForeignPtr a)

    bytestring Data.ByteString.Internal

    Most operations on a ByteString need to read from the buffer given by its ForeignPtr Word8 field. But since most operations on ByteString are (nominally) pure, their implementations cannot see the IO state thread that was used to initialize the contents of that buffer. This means that under some circumstances, these buffer-reads may be executed before the writes used to initialize the buffer are executed, with unpredictable results. deferForeignPtrAvailability exists to help solve this problem. At runtime, a call deferForeignPtrAvailability x is equivalent to pure $! x, but the former is more opaque to the simplifier, so that reads from the pointer in its result cannot be executed until the deferForeignPtrAvailability x call is complete. The opaque bits evaporate during CorePrep, so using deferForeignPtrAvailability incurs no direct overhead.

  3. fromForeignPtr :: ForeignPtr Word8 -> Int -> Int -> ByteString

    bytestring Data.ByteString.Internal

    O(1) Build a ByteString from a ForeignPtr. If you do not need the offset parameter then you should be using unsafePackCStringLen or unsafePackCStringFinalizer instead.

  4. fromForeignPtr0 :: ForeignPtr Word8 -> Int -> ByteString

    bytestring Data.ByteString.Internal

    No documentation available.

  5. nullForeignPtr :: ForeignPtr Word8

    bytestring Data.ByteString.Internal

    The 0 pointer. Used to indicate the empty Bytestring.

  6. plusForeignPtr :: ForeignPtr a -> Int -> ForeignPtr b

    bytestring Data.ByteString.Internal

    No documentation available.

  7. toForeignPtr :: ByteString -> (ForeignPtr Word8, Int, Int)

    bytestring Data.ByteString.Internal

    O(1) Deconstruct a ForeignPtr from a ByteString

  8. toForeignPtr0 :: ByteString -> (ForeignPtr Word8, Int)

    bytestring Data.ByteString.Internal

    O(1) Deconstruct a ForeignPtr from a ByteString

  9. unsafeWithForeignPtr :: ForeignPtr a -> (Ptr a -> IO b) -> IO b

    bytestring Data.ByteString.Internal

    No documentation available.

  10. asForeignPtr :: Text -> IO (ForeignPtr Word8, I8)

    text Data.Text.Foreign

    O(n) Make a mutable copy of a Text.

Page 401 of many | Previous | Next