MCPcopy Create free account
hub / github.com/danoon2/Boxedwine / try_enqueue

Method try_enqueue

source/util/concurrentqueue.h:1060–1064  ·  view source on GitHub ↗

Enqueues a single item (by copying it). Does not allocate memory. Fails if not enough room to enqueue (or implicit production is disabled because Traits::INITIAL_IMPLICIT_PRODUCER_HASH_SIZE is 0). Thread-safe.

Source from the content-addressed store, hash-verified

1058 // is 0).
1059 // Thread-safe.
1060 inline bool try_enqueue(T const& item)
1061 {
1062 MOODYCAMEL_CONSTEXPR_IF (INITIAL_IMPLICIT_PRODUCER_HASH_SIZE == 0) return false;
1063 else return inner_enqueue<CannotAlloc>(item);
1064 }
1065
1066 // Enqueues a single item (by moving it, if possible).
1067 // Does not allocate memory (except for one-time implicit producer).

Callers

nothing calls this directly

Calls 1

MOODYCAMEL_CONSTEXPR_IFFunction · 0.85

Tested by

no test coverage detected