[Libreoffice-commits] core.git: idl/inc idl/source

Bugra (via logerrit) logerrit at kemper.freedesktop.org
Wed Mar 11 16:37:34 UTC 2020


 idl/inc/lex.hxx             |   18 +++++++++---------
 idl/source/cmptools/lex.cxx |    4 ++--
 2 files changed, 11 insertions(+), 11 deletions(-)

New commits:
commit ad53c996205c290b88fd7acc9fa5c42c3eb5862b
Author:     Bugra <bugrakurt26 at gmail.com>
AuthorDate: Sun Mar 8 20:13:52 2020 +0300
Commit:     Michael Stahl <michael.stahl at cib.de>
CommitDate: Wed Mar 11 17:36:44 2020 +0100

    tdf#114441: Convert use of sal_uLong to better integer types
    
    Change-Id: I6b6f59a73aeda6af78fecaf4344826a943072033
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90191
    Tested-by: Jenkins
    Reviewed-by: Michael Stahl <michael.stahl at cib.de>

diff --git a/idl/inc/lex.hxx b/idl/inc/lex.hxx
index 977cc2b50a36..b7aa9336d82f 100644
--- a/idl/inc/lex.hxx
+++ b/idl/inc/lex.hxx
@@ -35,12 +35,12 @@ enum class SVTOKENTYPE { Empty,      Comment,
 class SvToken
 {
 friend class SvTokenStream;
-    sal_uLong               nLine, nColumn;
+    sal_uInt64              nLine, nColumn;
     SVTOKENTYPE             nType;
     OString                 aString;
     union
     {
-        sal_uInt64           nLong;
+        sal_uInt64          nLong;
         bool                bBool;
         char                cChar;
         SvStringHashEntry * pHash;
@@ -53,11 +53,11 @@ public:
 
     OString     GetTokenAsString() const;
 
-    void        SetLine( sal_uLong nLineP )     { nLine = nLineP;       }
-    sal_uLong   GetLine() const             { return nLine;         }
+    void        SetLine( sal_uInt64 nLineP )     { nLine = nLineP;       }
+    sal_uInt64  GetLine() const             { return nLine;         }
 
-    void        SetColumn( sal_uLong nColumnP ) { nColumn = nColumnP;   }
-    sal_uLong   GetColumn() const           { return nColumn;       }
+    void        SetColumn( sal_uInt64 nColumnP ) { nColumn = nColumnP;   }
+    sal_uInt64  GetColumn() const           { return nColumn;       }
 
     bool        IsComment() const   { return nType == SVTOKENTYPE::Comment; }
     bool        IsInteger() const   { return nType == SVTOKENTYPE::Integer; }
@@ -98,13 +98,13 @@ inline SvToken::SvToken()
 
 class SvTokenStream
 {
-    sal_uLong       nLine, nColumn;
+    sal_uInt64      nLine, nColumn;
     sal_Int32       nBufPos;
     char            c;          // next character
     static const sal_uInt16 nTabSize = 4;   // length of tabulator
     OString         aStrTrue;
     OString         aStrFalse;
-    sal_uLong       nMaxPos;
+    sal_uInt32      nMaxPos;
 
     std::unique_ptr<SvFileStream>          pInStream;
     OUString                               aFileName;
@@ -129,7 +129,7 @@ class SvTokenStream
     bool            IsEof() const { return pInStream->eof(); }
     void            SetMax()
                     {
-                        sal_uLong n = Tell();
+                        sal_uInt32 n = Tell();
                         if( n > nMaxPos )
                             nMaxPos = n;
                     }
diff --git a/idl/source/cmptools/lex.cxx b/idl/source/cmptools/lex.cxx
index f479bea4c4b7..eb9ad11703a2 100644
--- a/idl/source/cmptools/lex.cxx
+++ b/idl/source/cmptools/lex.cxx
@@ -204,8 +204,8 @@ bool SvTokenStream::MakeToken( SvToken & rToken )
     }
     while( 0 == c && !IsEof() && ( ERRCODE_NONE == pInStream->GetError() ) );
 
-    sal_uLong nLastLine     = nLine;
-    sal_uLong nLastColumn   = nColumn;
+    sal_uInt64 nLastLine     = nLine;
+    sal_uInt64 nLastColumn   = nColumn;
     // comment
     if( '/' == c )
     {


More information about the Libreoffice-commits mailing list