Skip to content

Commit 8dc66b4

Browse files
committed
Direct initialization of atomics
1 parent 349e7a1 commit 8dc66b4

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

include/kfr/cometa/memory.hpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ namespace details
1717

1818
struct memory_statistics
1919
{
20-
std::atomic_uintptr_t allocation_count = ATOMIC_VAR_INIT(0);
21-
std::atomic_uintptr_t allocation_size = ATOMIC_VAR_INIT(0);
22-
std::atomic_uintptr_t deallocation_count = ATOMIC_VAR_INIT(0);
23-
std::atomic_uintptr_t deallocation_size = ATOMIC_VAR_INIT(0);
20+
std::atomic_uintptr_t allocation_count{ 0 };
21+
std::atomic_uintptr_t allocation_size{ 0 };
22+
std::atomic_uintptr_t deallocation_count{ 0 };
23+
std::atomic_uintptr_t deallocation_size{ 0 };
2424
};
2525

2626
inline memory_statistics& get_memory_statistics()

0 commit comments

Comments
 (0)