Anklang 0.3.0-460-gc4ef46ba
ASE — Anklang Sound Engine (C++)
« « « Anklang Documentation |
#include "atomics.hh"
Public Member Functions | |
bool | empty () const |
Return true if the stack holds no items. | |
bool | push (Value &&value) |
Add value to top of the stack, returns if the stack was empty (true). | |
bool | push (const Value &value) |
Add a copy of value to top of the stack, returns if the stack was empty (true). | |
bool | pop (Value &value) |
Pop value from top of the stack, returns if value was reassigned (true), otherwise the stack was empty. | |
Thread-safe, lock-free stack based on MpmcStack and an Allocator with allows_read_after_free
.
Definition at line 179 of file atomics.hh.
bool Ase::AtomicStack< Value, GrowOnlyAllocator >::empty | ( | ) | const |
Return true
if the stack holds no items.
Definition at line 181 of file atomics.hh.
bool Ase::AtomicStack< Value, GrowOnlyAllocator >::pop | ( | Value & | value | ) |
Pop value
from top of the stack, returns if value
was reassigned (true), otherwise the stack was empty.
Definition at line 198 of file atomics.hh.
References std::destroy_at().
bool Ase::AtomicStack< Value, GrowOnlyAllocator >::push | ( | const Value & | value | ) |
Add a copy of value
to top of the stack, returns if the stack was empty (true).
Definition at line 192 of file atomics.hh.
References Ase::AtomicStack< Value, GrowOnlyAllocator >::push().
bool Ase::AtomicStack< Value, GrowOnlyAllocator >::push | ( | Value && | value | ) |
Add value
to top of the stack, returns if the stack was empty (true).
Definition at line 184 of file atomics.hh.
References std::construct_at().
Referenced by Ase::AtomicStack< Value, GrowOnlyAllocator >::push().