3-- Module : Streamly.Data.MutArray
4-- Copyright : (c) 2022 Composewell Technologies
7-- Maintainer : streamly@composewell.com
11-- This module provides a mutable version of "Streamly.Data.Array". The
12-- contents of a mutable array can be modified in-place. For general
13-- documentation, please refer to the original module.
15-- Please refer to "Streamly.Internal.Data.MutArray" for functions that have
16-- not yet been released.
18-- For mutable arrays that work on boxed types, not requiring the 'Unbox'
19-- constraint, please refer to "Streamly.Data.MutArray.Generic".
21module Streamly.Data.MutArray
24 -- | To execute the code examples provided in this module in ghci, please
25 -- run the following commands first.
29 -- * Mutable Array Type
34 -- Uninitialized Arrays
45 -- * Pinning & Unpinning
50 -- * Appending elements
53 -- * Appending streams
100import Prelude hiding (length, read)
101import Streamly.Internal.Data.MutArray
102import Streamly.Internal.Data.Unbox (Unbox (..))
103import Control.Monad.IO.Class (MonadIO)
105#include "DocTestDataMutArray.hs"
107{-# DEPRECATED newPinned "Please use pinnedNew instead." #-}
108{-# INLINE newPinned #-}
109newPinned :: forall m a. (MonadIO m, Unbox a) => Int -> m (MutArray a)
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list