atomicCompareExchange

nint atomicCompareExchange(overload nint* dest, nint expected, nint value)

Atomically stores a signed native integer when the current value matches expected.

Returns

The value that was stored before the operation.

overload nint*
dest

The storage location to update.

nint
expected

The value that must currently be stored for the exchange to occur.

nint
value

The value to store when expected matches.

nuint atomicCompareExchange(overload nuint* dest, nuint expected, nuint value)

Atomically stores an unsigned native integer when the current value matches expected.

Returns

The value that was stored before the operation.

overload nuint*
dest

The storage location to update.

nuint
expected

The value that must currently be stored for the exchange to occur.

nuint
value

The value to store when expected matches.

void* atomicCompareExchange(overload void** dest, void* expected, void* value)

Atomically stores a pointer when the current value matches expected.

Returns

The value that was stored before the operation.

Symbol

atomicCompareExchangePtr

overload void**
dest

The storage location to update.

void*
expected

The value that must currently be stored for the exchange to occur.

void*
value

The value to store when expected matches.

Generated with campc v0.4.0-preview.1+d50446ef951a6ed675f7086cf093dbc993f0041b.