Add missing includes of <iterator>
Since https://github.com/llvm/llvm-project/commit/4cd04d1687f1096990119304a3eb22081ab4bb29, libcxx no longer transitively includes in a number of places. Make sure to explicitly include this header where it's needed.