list/swap_consecutive_elements cleanups