atomicLoad

Loads 'val' from memory and returns it. The memory barrier specified by 'ms' is applied to the operation, which is fully sequenced by default. Valid memory orders are MemoryOrder.raw, MemoryOrder.acq, and MemoryOrder.seq.

  1. T atomicLoad(ref const T val)
    pure nothrow @nogc @trusted
    T
    atomicLoad
    (
    ref const T val
    )
    if (
    !is(T == shared U,
    U
    ) &&
    !is(T == shared inout U,
    U
    )
    &&
    !is(T == shared const U,
    U
    )
    )
  2. T atomicLoad(ref shared const T val)
  3. TailShared!T atomicLoad(ref shared const T val)

Parameters

val
Type: T

The target variable.

Return Value

Type: T

The value of 'val'.

Suggestion Box / Bug Report