MCPcopy Create free account
hub / github.com/Snapchat/KeyDB / swap

Method swap

deps/concurrentqueue/concurrentqueue.h:653–662  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

651 }
652
653 void swap(ProducerToken& other) MOODYCAMEL_NOEXCEPT
654 {
655 std::swap(producer, other.producer);
656 if (producer != nullptr) {
657 producer->token = this;
658 }
659 if (other.producer != nullptr) {
660 other.producer->token = &other;
661 }
662 }
663
664 // A token is always valid unless:
665 // 1) Memory allocation failed during construction

Callers 4

UDPSenderMethod · 0.45
ConcurrentQueueClass · 0.45
swapFunction · 0.45

Calls 1

swapFunction · 0.70

Tested by

no test coverage detected