Kaydet (Commit) 54250655 authored tarafından Caolán McNamara's avatar Caolán McNamara

fix higher debug level build

Change-Id: I091a198bc1fac17434ae64c18560dda48d6d5142
üst 4d25561e
...@@ -169,7 +169,7 @@ class SwCalc ...@@ -169,7 +169,7 @@ class SwCalc
{ {
SwHash* VarTable[ TBLSZ ]; SwHash* VarTable[ TBLSZ ];
String aVarName, sCurrSym; String aVarName, sCurrSym;
String sCommand; OUString sCommand;
std::vector<const SwUserFieldType*> aRekurStk; std::vector<const SwUserFieldType*> aRekurStk;
SwSbxValue nLastLeft; SwSbxValue nLastLeft;
SwSbxValue nNumberValue; SwSbxValue nNumberValue;
......
...@@ -646,7 +646,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -646,7 +646,7 @@ SwCalcOper SwCalc::GetToken()
{ {
#endif #endif
if( nCommandPos >= sCommand.Len() ) if( nCommandPos >= sCommand.getLength() )
return eCurrOper = CALC_ENDCALC; return eCurrOper = CALC_ENDCALC;
using namespace ::com::sun::star::i18n; using namespace ::com::sun::star::i18n;
...@@ -666,8 +666,8 @@ SwCalcOper SwCalc::GetToken() ...@@ -666,8 +666,8 @@ SwCalcOper SwCalc::GetToken()
} }
else if( aRes.TokenType & KParseType::IDENTNAME ) else if( aRes.TokenType & KParseType::IDENTNAME )
{ {
String aName( sCommand.Copy( nRealStt, String aName( sCommand.copy( nRealStt,
static_cast<xub_StrLen>(aRes.EndPos) - nRealStt )); aRes.EndPos - nRealStt ) );
//#101436#: The variable may contain a database name. It must not be //#101436#: The variable may contain a database name. It must not be
// converted to lower case! Instead all further comparisons must be // converted to lower case! Instead all further comparisons must be
// done case-insensitive // done case-insensitive
...@@ -716,8 +716,8 @@ SwCalcOper SwCalc::GetToken() ...@@ -716,8 +716,8 @@ SwCalcOper SwCalc::GetToken()
} }
else if( aRes.TokenType & KParseType::ONE_SINGLE_CHAR ) else if( aRes.TokenType & KParseType::ONE_SINGLE_CHAR )
{ {
String aName( sCommand.Copy( nRealStt, String aName( sCommand.copy( nRealStt,
static_cast<xub_StrLen>(aRes.EndPos) - nRealStt )); aRes.EndPos - nRealStt ));
if( 1 == aName.Len() ) if( 1 == aName.Len() )
{ {
bSetError = false; bSetError = false;
...@@ -755,8 +755,8 @@ SwCalcOper SwCalc::GetToken() ...@@ -755,8 +755,8 @@ SwCalcOper SwCalc::GetToken()
else else
eCurrOper = CALC_NOT, eTmp2 = CALC_NEQ; eCurrOper = CALC_NOT, eTmp2 = CALC_NEQ;
if( aRes.EndPos < sCommand.Len() && if( aRes.EndPos < sCommand.getLength() &&
'=' == sCommand.GetChar( (xub_StrLen)aRes.EndPos ) ) '=' == sCommand[aRes.EndPos] )
{ {
eCurrOper = eTmp2; eCurrOper = eTmp2;
++aRes.EndPos; ++aRes.EndPos;
...@@ -769,32 +769,32 @@ SwCalcOper SwCalc::GetToken() ...@@ -769,32 +769,32 @@ SwCalcOper SwCalc::GetToken()
break; break;
case '[': case '[':
if( aRes.EndPos < sCommand.Len() ) if( aRes.EndPos < sCommand.getLength() )
{ {
aVarName.Erase(); aVarName.Erase();
xub_StrLen nFndPos = (xub_StrLen)aRes.EndPos, sal_Int32 nFndPos = aRes.EndPos,
nSttPos = nFndPos; nSttPos = nFndPos;
do { do {
if( STRING_NOTFOUND != ( nFndPos = if( -1 != ( nFndPos =
sCommand.Search( ']', nFndPos )) ) sCommand.indexOf( ']', nFndPos )) )
{ {
// ignore the ] // ignore the ]
if( '\\' == sCommand.GetChar(nFndPos-1)) if ('\\' == sCommand[nFndPos-1])
{ {
aVarName += sCommand.Copy( nSttPos, aVarName += sCommand.copy( nSttPos,
nFndPos - nSttPos - 1 ); nFndPos - nSttPos - 1 );
nSttPos = ++nFndPos; nSttPos = ++nFndPos;
} }
else else
break; break;
} }
} while( STRING_NOTFOUND != nFndPos ); } while( nFndPos != -1 );
if( STRING_NOTFOUND != nFndPos ) if( nFndPos != -1 )
{ {
if( nSttPos != nFndPos ) if( nSttPos != nFndPos )
aVarName += sCommand.Copy( nSttPos, aVarName += sCommand.copy( nSttPos,
nFndPos - nSttPos ); nFndPos - nSttPos );
aRes.EndPos = nFndPos + 1; aRes.EndPos = nFndPos + 1;
eCurrOper = CALC_NAME; eCurrOper = CALC_NAME;
...@@ -816,8 +816,8 @@ SwCalcOper SwCalc::GetToken() ...@@ -816,8 +816,8 @@ SwCalcOper SwCalc::GetToken()
} }
else if( aRes.TokenType & KParseType::BOOLEAN ) else if( aRes.TokenType & KParseType::BOOLEAN )
{ {
String aName( sCommand.Copy( nRealStt, String aName( sCommand.copy( nRealStt,
static_cast<xub_StrLen>(aRes.EndPos) - nRealStt )); aRes.EndPos - nRealStt ));
if( aName.Len() ) if( aName.Len() )
{ {
sal_Unicode ch = aName.GetChar(0); sal_Unicode ch = aName.GetChar(0);
...@@ -837,7 +837,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -837,7 +837,7 @@ SwCalcOper SwCalc::GetToken()
} }
} }
} }
else if( nRealStt == sCommand.Len() ) else if( nRealStt == sCommand.getLength() )
{ {
eCurrOper = CALC_ENDCALC; eCurrOper = CALC_ENDCALC;
bSetError = false; bSetError = false;
...@@ -852,7 +852,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -852,7 +852,7 @@ SwCalcOper SwCalc::GetToken()
}; };
#if OSL_DEBUG_LEVEL > 1 #if OSL_DEBUG_LEVEL > 1
#define NextCh( s, n ) (nCommandPos < sCommand.Len() ? sCommand.GetChar( nCommandPos++ ) : 0) #define NextCh( s, n ) (nCommandPos < sCommand.getLength() ? sCommand[nCommandPos++] : 0)
} }
else else
...@@ -880,8 +880,8 @@ SwCalcOper SwCalc::GetToken() ...@@ -880,8 +880,8 @@ SwCalcOper SwCalc::GetToken()
case '\n': case '\n':
{ {
sal_Unicode c; sal_Unicode c;
while( nCommandPos < sCommand.Len() && while( nCommandPos < sCommand.getLength() &&
( ( c = sCommand.GetChar( nCommandPos ) ) == ' ' || ( ( c = sCommand[nCommandPos] ) == ' ' ||
c == '\t' || c == '\x0a' || c == '\x0d' )) c == '\t' || c == '\x0a' || c == '\x0d' ))
{ {
++nCommandPos; ++nCommandPos;
...@@ -902,7 +902,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -902,7 +902,7 @@ SwCalcOper SwCalc::GetToken()
break; break;
case '=': case '=':
if( '=' == sCommand.GetChar( nCommandPos ) ) if( '=' == sCommand[nCommandPos] )
{ {
++nCommandPos; ++nCommandPos;
eCurrOper = CALC_EQ; eCurrOper = CALC_EQ;
...@@ -914,7 +914,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -914,7 +914,7 @@ SwCalcOper SwCalc::GetToken()
break; break;
case '!': case '!':
if( '=' == sCommand.GetChar( nCommandPos ) ) if( '=' == sCommand[nCommandPos] )
{ {
++nCommandPos; ++nCommandPos;
eCurrOper = CALC_NEQ; eCurrOper = CALC_NEQ;
...@@ -928,7 +928,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -928,7 +928,7 @@ SwCalcOper SwCalc::GetToken()
case '>': case '>':
case '<': case '<':
eCurrOper = '>' == ch ? CALC_GRE : CALC_LES; eCurrOper = '>' == ch ? CALC_GRE : CALC_LES;
if( '=' == (ch = sCommand.GetChar( nCommandPos ) ) ) if( '=' == (ch = sCommand[nCommandPos] ) )
{ {
++nCommandPos; ++nCommandPos;
eCurrOper = CALC_GRE == eCurrOper ? CALC_GEQ : CALC_LEQ; eCurrOper = CALC_GRE == eCurrOper ? CALC_GEQ : CALC_LEQ;
...@@ -1023,7 +1023,7 @@ SwCalcOper SwCalc::GetToken() ...@@ -1023,7 +1023,7 @@ SwCalcOper SwCalc::GetToken()
if( ch ) if( ch )
--nCommandPos; --nCommandPos;
String aStr( sCommand.Copy( nStt, nCommandPos-nStt )); String aStr( sCommand.copy( nStt, nCommandPos-nStt ));
aStr = pCharClass->lowercase( aStr ); aStr = pCharClass->lowercase( aStr );
// catch currency symbol // catch currency symbol
...@@ -1481,7 +1481,7 @@ String SwCalc::GetDBName(const String& rName) ...@@ -1481,7 +1481,7 @@ String SwCalc::GetDBName(const String& rName)
SwDBData aData = rDoc.GetDBData(); SwDBData aData = rDoc.GetDBData();
String sRet = aData.sDataSource; String sRet = aData.sDataSource;
sRet += DB_DELIM; sRet += DB_DELIM;
sRet += String(aData.sCommand); sRet += aData.sCommand;
return sRet; return sRet;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment