back.bringToFront
size_t bringToFront(InputRange, ForwardRange)(InputRange front, ForwardRange back) if (isInputRange!InputRange && isForwardRange!ForwardRange)bringToFront takes two ranges front and back, which may be of different types. Considering the concatenation of front and back one unified range, bringToFront rotates that unified range such that all elements in back are brought to the beginning of the unified range. The relative ordering of elements in front and back, respectively, remains unchanged.
The bringToFront function treats strings at the code unit level and it is not concerned with Unicode character integrity. bringToFront is designed as a function for moving elements in ranges, not as a string function.
Performs max(front.length, back.length) evaluations of swap.
The bringToFront function can rotate elements in one buffer left or right, swap buffers of equal length, and even move elements across disjoint buffers of different types and different lengths.
Preconditions:
Either front and back are disjoint, or back is reachable from front and front is not reachable from back.
Parameters
front | an input range |
back | a forward range |