diff options
Diffstat (limited to 'src/mbgl')
-rw-r--r-- | src/mbgl/style/style.cpp | 4 | ||||
-rw-r--r-- | src/mbgl/text/glyph_atlas.cpp | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/src/mbgl/style/style.cpp b/src/mbgl/style/style.cpp index 97d30b2494..9cd8cda1ec 100644 --- a/src/mbgl/style/style.cpp +++ b/src/mbgl/style/style.cpp @@ -583,8 +583,8 @@ RenderData Style::getRenderData(MapDebugOptions debugOptions, float angle) const } std::vector<std::reference_wrapper<RenderTile>> sortedTilesForInsertion; - for (auto tileIt = sortedTiles.begin(); tileIt != sortedTiles.end(); ++tileIt) { - auto& tile = tileIt->get(); + for (auto& sortedTile : sortedTiles) { + auto& tile = sortedTile.get(); if (!tile.tile.isRenderable()) { continue; } diff --git a/src/mbgl/text/glyph_atlas.cpp b/src/mbgl/text/glyph_atlas.cpp index 4feaab01f9..b43971f704 100644 --- a/src/mbgl/text/glyph_atlas.cpp +++ b/src/mbgl/text/glyph_atlas.cpp @@ -207,8 +207,8 @@ Rect<uint16_t> GlyphAtlas::addGlyph(GlyphValue& value) { } void GlyphAtlas::removeGlyphValues(GlyphRequestor& requestor, std::map<GlyphID, GlyphValue>& values) { - for (auto it = values.begin(); it != values.end(); it++) { - GlyphValue& value = it->second; + for (auto& it : values) { + GlyphValue& value = it.second; if (value.ids.erase(&requestor) && value.ids.empty() && value.rect) { const Rect<uint16_t>& rect = *value.rect; @@ -228,8 +228,8 @@ void GlyphAtlas::removeGlyphValues(GlyphRequestor& requestor, std::map<GlyphID, } void GlyphAtlas::removePendingRanges(mbgl::GlyphRequestor& requestor, std::map<GlyphRange, GlyphRequest>& ranges) { - for (auto it = ranges.begin(); it != ranges.end(); it++) { - it->second.requestors.erase(&requestor); + for (auto& range : ranges) { + range.second.requestors.erase(&requestor); } } |