HORIZON HASKELLDocslts/ghc-10.0.xc7d136e2026-10-12Search names, modules, packages, or :: a typeCtrl K

GHC 10.0.0.20260917 · lts/ghc-10.0.x · c7d136e · 2026-10-12

Moduleprimitive-0.9.1.0

Data.Primitive.Ptr

  • 1 type
  • 11 values
valuenullPtr :: Ptr a
#

The constant nullPtr contains a distinguished value of Ptr that is not associated with a valid memory location.

datadata Ptr a
#

A value of type Ptr a represents a pointer to an object, or an array of objects, which may be marshalled to or from Haskell values of type a.

The type a will often be an instance of class Storable which provides the marshalling operations. However this is not essential, and you can provide your own operations to access the pointer. For example you might write small foreign functions to get or set the fields of a C struct.

Constructors

Instances19NFData1, Generic1, Data, Foldable, Traversable, Storable, …