Switch around iterator types for compiler compatibility