Bug 1251995 followup - Fix declaration shadow error.
☠☠ backed out by 383555f19d02 ☠ ☠
authorXidorn Quan <quanxunzhen@gmail.com>
Mon, 07 Mar 2016 17:29:41 +0800
changeset 324949 6cacb08f6f5ca0f3345288c5ed4d707352a22fe9
parent 324948 2c532283a04f1170240f569b5297bce20adca292
child 324950 33a9e4482bcc32edfca58a1edb98eb22d993d0a3
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1251995
milestone47.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1251995 followup - Fix declaration shadow error.
gfx/thebes/gfxTextRun.cpp
--- a/gfx/thebes/gfxTextRun.cpp
+++ b/gfx/thebes/gfxTextRun.cpp
@@ -969,22 +969,22 @@ gfxTextRun::BreakAndMeasureText(uint32_t
         trimmableChars = lastBreakTrimmableChars;
         trimmableAdvance = lastBreakTrimmableAdvance;
         usedHyphenation = lastBreakUsedHyphenation;
     } else {
         charsFit = aMaxLength;
     }
 
     if (aMetrics) {
-        auto end = aStart + charsFit;
-        *aMetrics = MeasureText(Range(aStart, end), aBoundingBoxType,
+        auto fitEnd = aStart + charsFit;
+        *aMetrics = MeasureText(Range(aStart, fitEnd), aBoundingBoxType,
                                 aRefDrawTarget, aProvider);
         if (trimmableChars) {
             Metrics trimMetrics =
-                MeasureText(Range(end - trimmableChars, end),
+                MeasureText(Range(fitEnd - trimmableChars, fitEnd),
                             aBoundingBoxType, aRefDrawTarget, aProvider);
             aMetrics->mAdvanceWidth -= trimMetrics.mAdvanceWidth;
         }
     }
     if (aTrimWhitespace) {
         *aTrimWhitespace = trimmableAdvance;
     }
     if (aUsedHyphenation) {