Moduleghc-boot-10.0.0.20260917GHC2024
GHC.Data.SmallArray
Small-array
- 3 types
- 19 values
- Packageghc-boot-10.0.0.20260917
- Exports22
- LanguageGHC2024
- LicenceBSD-3-Clause
- SourceSmallArray.hs
Constructors
Instances2Show, Binary
Show a => Show (SmallArray a)Defined in ghc-boot-10.0.0.20260917 · GHC.Data.SmallArrayBinary a => Binary (SmallArray a)Defined in ghc-boot-10.0.0.20260917 · GHC.Data.SmallArray
newSmallArray :: Intsize
-> ainitial contents
-> State# s-> (# State# s, SmallMutableArray s a #)
freezeSmallArray :: SmallMutableArray s asource
-> Intoffset
-> Intlength
-> State# s-> (# State# s, SmallArray a #)
Copy and freeze a slice of a mutable array.
Freeze a mutable array (no copy!)
Index a small-array (no bounds checking!)
Get the size of a SmallArray
Convert a list into an array.
Construct a SmallArray from a list. This is different from listToArray since the list elements fill the SmallArray sequentially without recalculating the indices or remapping to other element types.
Construct a list from a SmallArray.
Map a function over the elements of a SmallArray
Fold the values of a SmallArray into a 'Monoid m' of choice
Execute the IO action the given number of times and store the results in a SmallArray.
Apply the IO action to every element, producing a new SmallArray.
Apply the monadic action to every element, ignoring the results.
Apply the monadic action to every element and its index, ignoring the results.
Force the elements of the given SmallArray