switch to iterator to handle concurrentmodification possibility
something is modifying this list elsewhere while we are iterating
through it. that is confusing, but at least, using an iterator
means we won't crash because of it
improve debug support and error handling