Kaydet (Commit) b9a51c0b authored tarafından Eike Rathke's avatar Eike Rathke

assert "can't happen"

Change-Id: I896e29b04568b351517612a1ac161dca5717dfbc
üst 92877608
......@@ -2575,6 +2575,9 @@ void ScInterpreter::ScRoman()
if( (nDigit % 5) == 4 )
{
// assert can't happen with nVal<4000 precondition
assert( ((nDigit == 4) ? (nIndex >= 1) : (nIndex >= 2)));
sal_uInt16 nIndex2 = (nDigit == 4) ? nIndex - 1 : nIndex - 2;
sal_uInt16 nSteps = 0;
while( (nSteps < nMode) && (nIndex < nMaxIndex) )
......@@ -2593,7 +2596,11 @@ void ScInterpreter::ScRoman()
else
{
if( nDigit > 4 )
{
// assert can't happen with nVal<4000 precondition
assert( nIndex >= 1 );
aRoman += pChars[ nIndex - 1 ];
}
sal_Int32 nPad = nDigit % 5;
if (nPad)
{
......
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