Refactor. Stop using memory for list copies.
Merge pull request #2509 from tomwys/patch-2

Refactor. Stop using memory for list copies.