Make take_last_while return elements in the original order.