Clean up copying operations.  Add comments.