diff --git a/aegisub/src/block_cache.h b/aegisub/src/block_cache.h index 7d9bd62ba..a2748f091 100644 --- a/aegisub/src/block_cache.h +++ b/aegisub/src/block_cache.h @@ -218,8 +218,9 @@ public: // Get a list of macro blocks sorted by access count std::vector access_data; access_data.reserve(data.size()); - for (typename MacroBlockArray::iterator mb = data.begin(); mb != data.end(); ++mb) - access_data.push_back(AccessData(&*mb)); + // For whatever reason, G++ pukes if I try using iterators here... + for (size_t mbi = 0; mbi != data.size(); ++mbi) + access_data.push_back(AccessData(&data[mbi])); std::sort(access_data.begin(), access_data.end()); // Sum up data size until we hit the max