IORefCAS-0.2: Atomic compare and swap for IORefs and STRefs.

Safe HaskellNone

Data.CAS.Internal.Foreign

Description

This is a version of CAS that works outside of Haskell by using the FFI (and the GCC intrinsics-based Atomic.)

Documentation

data CASRef a

Instances

CASable CASRef Word32

EXAMPLE SPECIALIZATION: a more efficient implementation for simple scalars.

Boilerplate TODO: We Should have one of these for all word-sized Scalar types.