HORIZON HASKELLDocslts/ghc-9.10.x248f8f02026-10-05Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05

Moduleprimitive-unlifted-2.1.0.0Haskell2010

Data.Primitive.Unlifted.SmallArray.ST

A version of the Data.Primitive.Unlifted.SmallArray interface specialized to ST. This is intended primarily so library developers can easily check whether the basic operations are unboxed properly, but its more constrained type signatures also offer somewhat better type inference where applicable.

  • 4 types
  • 33 values

Types

4 declarations
datadata SmallUnliftedArray_ a (unlifted_a :: UnliftedType)
#

A SmallUnliftedArray_ a unlifted_a represents an array of values of a lifted type a that wrap values of an unlifted type unlifted_a. It is expected that unlifted_a ~ Unlifted a, but imposing that constraint here would force the type roles to nominal, which is often undesirable when arrays are used as components of larger datatypes.

Constructors

Instances8IsList, Eq, Show, Semigroup, Monoid, PrimUnlifted, …
datadata SmallMutableUnliftedArray_ s a (unlifted_a :: UnliftedType)
#
Instances3Eq, PrimUnlifted, Unlifted

Operations

22 declarations

Creates a new MutableUnliftedArray. This function is unsafe because it initializes all elements of the array as pointers to the empty array. Attempting to read one of these elements before writing to it is in effect an unsafe coercion from UnliftedArray a to the element type.

List Conversion

3 declarations

Folding

5 declarations

Traversals

2 declarations

Mapping

1 declaration