operator–

operator–#

stdgpu: stdgpu::atomic::operator--
stdgpu Latest
Efficient STL-like Data Structures on the GPU

◆ operator--() [1/2]

template<typename T , typename Allocator = safe_device_allocator<T>>
template<STDGPU_DETAIL_OVERLOAD_IF(std::is_integral_v< T >) >
STDGPU_DEVICE_ONLY T stdgpu::atomic< T, Allocator >::operator-- ( )
noexcept

Atomically decrements the current value. Equivalent to fetch_sub(1) - 1.

Returns
The new value