Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1858)

Unified Diff: Source/platform/fonts/opentype/OpenTypeVerticalData.cpp

Issue 951603002: Rename inner index variable to avoid variable shadowing. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/fonts/opentype/OpenTypeVerticalData.cpp
diff --git a/Source/platform/fonts/opentype/OpenTypeVerticalData.cpp b/Source/platform/fonts/opentype/OpenTypeVerticalData.cpp
index 45ce79b16d4dad4bf21a178563fa70e740edc4bc..61f7e24d6e0d551d7fa90274f69808f0d1229553 100644
--- a/Source/platform/fonts/opentype/OpenTypeVerticalData.cpp
+++ b/Source/platform/fonts/opentype/OpenTypeVerticalData.cpp
@@ -176,8 +176,8 @@ struct LookupTable : TableBase {
uint16_t countFrom = coverage1->glyphCount;
if (!isValidEnd(buffer, &coverage1->glyphArray[countFrom]) || countTo != countFrom)
return false;
- for (uint16_t i = 0; i < countTo; ++i)
- map->set(coverage1->glyphArray[i], singleSubstitution2->substitute[i]);
+ for (uint16_t j = 0; j < countTo; ++j)
+ map->set(coverage1->glyphArray[j], singleSubstitution2->substitute[j]);
break;
}
case 2: { // Coverage Format 2 (e.g., Adobe Kozuka Gothic)
@@ -187,9 +187,9 @@ struct LookupTable : TableBase {
uint16_t countRange = coverage2->rangeCount;
if (!isValidEnd(buffer, &coverage2->ranges[countRange]))
return false;
- for (uint16_t i = 0, indexTo = 0; i < countRange; ++i) {
- uint16_t from = coverage2->ranges[i].start;
- uint16_t fromEnd = coverage2->ranges[i].end + 1; // OpenType "end" is inclusive
+ for (uint16_t j = 0, indexTo = 0; j < countRange; ++j) {
+ uint16_t from = coverage2->ranges[j].start;
+ uint16_t fromEnd = coverage2->ranges[j].end + 1; // OpenType "end" is inclusive
if (indexTo + (fromEnd - from) > countTo)
return false;
for (; from != fromEnd; ++from, ++indexTo)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698