diff --git a/include/vk_mem_alloc.h b/include/vk_mem_alloc.h index c802331..b787c36 100644 --- a/include/vk_mem_alloc.h +++ b/include/vk_mem_alloc.h @@ -4006,6 +4006,8 @@ template struct AtomicTransactionalIncrement { public: + using T = decltype(AtomicT().load()); + ~AtomicTransactionalIncrement() { if(m_Atomic) @@ -4013,7 +4015,7 @@ public: } void Commit() { m_Atomic = nullptr; } - typename AtomicT::value_type Increment(AtomicT* atomic) + T Increment(AtomicT* atomic) { m_Atomic = atomic; return m_Atomic->fetch_add(1);