MCPcopy Create free account
hub / github.com/cameron314/concurrentqueue / swap

Method swap

benchmarks/dlib/queue/queue_kernel_1.h:358–380  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

356 typename mem_manager
357 >
358 void queue_kernel_1<T,mem_manager>::
359 swap (
360 queue_kernel_1<T,mem_manager>& item
361 )
362 {
363 node* in_temp = in;
364 node* out_temp = out;
365 unsigned long queue_size_temp = queue_size;
366 node* current_element_temp = current_element;
367 bool at_start_temp = at_start_;
368
369 in = item.in;
370 out = item.out;
371 queue_size = item.queue_size;
372 current_element = item.current_element;
373 at_start_ = item.at_start_;
374
375 item.in = in_temp;
376 item.out = out_temp;
377 item.queue_size = queue_size_temp;
378 item.current_element = current_element_temp;
379 item.at_start_ = at_start_temp;
380 }
381
382// ----------------------------------------------------------------------------------------
383// ----------------------------------------------------------------------------------------

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected