Avoid modifying the collection we are iterating. Fixes #13.