Don't need to set pos = beg; can just receive pos instead of the beg arg and go to town.
size_t index = t-TravelerList::allusers.data;could thus become the loop init-statement, but...
Probably faster to receive index in a register as a function argument than to go into main memory and recalculate it.
It's already kicking around in the TravelerList ctor, right? Review & be sure.
pos = beg
; can just receivepos
instead of thebeg
arg and go to town.size_t index = t-TravelerList::allusers.data;
could thus become the loop init-statement, but...index
in a register as a function argument than to go into main memory and recalculate it. It's already kicking around in theTravelerList
ctor, right? Review & be sure.