[Libreoffice-commits] core.git: svl/source

Noel Grandin noel.grandin at collabora.co.uk
Thu Aug 3 09:47:16 UTC 2017


 svl/source/numbers/zforfind.cxx |   10 +++++-----
 svl/source/numbers/zforfind.hxx |   16 ++++++++--------
 2 files changed, 13 insertions(+), 13 deletions(-)

New commits:
commit 1972e4691961a6424b772dcf7570181d3c50369a
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date:   Thu Aug 3 10:54:41 2017 +0200

    rename SV_MAX_ANZ_INPUT_STRINGS->SV_MAX_COUNT_INPUT_STRINGS
    
    Change-Id: Ib915eb709966b7a487e54694ae3be7e5c2d3a452
    Reviewed-on: https://gerrit.libreoffice.org/40701
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/svl/source/numbers/zforfind.cxx b/svl/source/numbers/zforfind.cxx
index 3c241585a547..ed141de29935 100644
--- a/svl/source/numbers/zforfind.cxx
+++ b/svl/source/numbers/zforfind.cxx
@@ -126,7 +126,7 @@ void ImpSvNumberInputScan::Reset()
     nDatePatternNumbers = 0;
     nCanForceToIso8601 = 0;
 
-    for (sal_uInt32 i = 0; i < SV_MAX_ANZ_INPUT_STRINGS; i++)
+    for (sal_uInt32 i = 0; i < SV_MAX_COUNT_INPUT_STRINGS; i++)
     {
         IsNum[i] = false;
         nNums[i] = 0;
@@ -286,7 +286,7 @@ bool ImpSvNumberInputScan::NextNumberStringSymbol( const sal_Unicode*& pStr,
 
 
 // FIXME: should be grouping; it is only used though in case nStringsCnt is
-// near SV_MAX_ANZ_INPUT_STRINGS, in NumberStringDivision().
+// near SV_MAX_COUNT_INPUT_STRINGS, in NumberStringDivision().
 
 bool ImpSvNumberInputScan::SkipThousands( const sal_Unicode*& pStr,
                                           OUString& rSymbol )
@@ -358,14 +358,14 @@ void ImpSvNumberInputScan::NumberStringDivision( const OUString& rString )
 {
     const sal_Unicode* pStr = rString.getStr();
     const sal_Unicode* const pEnd = pStr + rString.getLength();
-    while ( pStr < pEnd && nStringsCnt < SV_MAX_ANZ_INPUT_STRINGS )
+    while ( pStr < pEnd && nStringsCnt < SV_MAX_COUNT_INPUT_STRINGS )
     {
         if ( NextNumberStringSymbol( pStr, sStrArray[nStringsCnt] ) )
         {   // Number
             IsNum[nStringsCnt] = true;
             nNums[nAnzNums] = nStringsCnt;
             nAnzNums++;
-            if (nStringsCnt >= SV_MAX_ANZ_INPUT_STRINGS - 7 &&
+            if (nStringsCnt >= SV_MAX_COUNT_INPUT_STRINGS - 7 &&
                 nPosThousandString == 0) // Only once
             {
                 if ( SkipThousands( pStr, sStrArray[nStringsCnt] ) )
@@ -3035,7 +3035,7 @@ bool ImpSvNumberInputScan::IsNumberFormatMain( const OUString& rString,        /
 {
     Reset();
     NumberStringDivision( rString );             // breakdown into strings and numbers
-    if (nStringsCnt >= SV_MAX_ANZ_INPUT_STRINGS) // too many elements
+    if (nStringsCnt >= SV_MAX_COUNT_INPUT_STRINGS) // too many elements
     {
         return false;                            // Njet, Nope, ...
     }
diff --git a/svl/source/numbers/zforfind.hxx b/svl/source/numbers/zforfind.hxx
index 4df9cd6ebe4b..72177d1d3fe6 100644
--- a/svl/source/numbers/zforfind.hxx
+++ b/svl/source/numbers/zforfind.hxx
@@ -28,7 +28,7 @@ class Date;
 class SvNumberformat;
 class SvNumberFormatter;
 
-#define SV_MAX_ANZ_INPUT_STRINGS  20    // max count of substrings in input scanner
+#define SV_MAX_COUNT_INPUT_STRINGS  20    // max count of substrings in input scanner
 
 class ImpSvNumberInputScan
 {
@@ -89,13 +89,13 @@ private:
     bool    bScanPartitiveMonths;               //* Whether to scan an input for partitive months
     Date* pNullDate;                            //* 30Dec1899
     // Variables for provisional results:
-    OUString sStrArray[SV_MAX_ANZ_INPUT_STRINGS]; //* Array of scanned substrings
-    bool       IsNum[SV_MAX_ANZ_INPUT_STRINGS];   //* Whether a substring is numeric
-    sal_uInt16 nNums[SV_MAX_ANZ_INPUT_STRINGS];   //* Sequence of offsets to numeric strings
-    sal_uInt16 nStringsCnt;                       //* Total count of scanned substrings
-    sal_uInt16 nAnzNums;                          //* Count of numeric substrings
-    bool   bDecSepInDateSeps;                     //* True <=> DecSep in {.,-,/,DateSep}
-    sal_uInt8   nMatchedAllStrings;               //* Scan...String() matched all substrings,
+    OUString   sStrArray[SV_MAX_COUNT_INPUT_STRINGS];//* Array of scanned substrings
+    bool       IsNum[SV_MAX_COUNT_INPUT_STRINGS];    //* Whether a substring is numeric
+    sal_uInt16 nNums[SV_MAX_COUNT_INPUT_STRINGS];    //* Sequence of offsets to numeric strings
+    sal_uInt16 nStringsCnt;                          //* Total count of scanned substrings
+    sal_uInt16 nAnzNums;                             //* Count of numeric substrings
+    bool       bDecSepInDateSeps;                    //* True <=> DecSep in {.,-,/,DateSep}
+    sal_uInt8  nMatchedAllStrings;                   //* Scan...String() matched all substrings,
 
     // bit mask of nMatched... constants
     static const sal_uInt8 nMatchedEndString;        // 0x01


More information about the Libreoffice-commits mailing list