Remove near-duplicated code.
Change-Id: I46e743ae47c76c4e9c22d092f501636ebab92878 Reviewed-on: https://gerrit.libreoffice.org/35606 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Kohei Yoshida <libreoffice@kohei.us>
This commit is contained in:
committed by
Kohei Yoshida
parent
522e9c65fa
commit
a7ad759726
@@ -940,26 +940,11 @@ void ScInterpreter::SingleRefToVars( const ScSingleRefData & rRef,
|
|||||||
|
|
||||||
void ScInterpreter::PopSingleRef(SCCOL& rCol, SCROW &rRow, SCTAB& rTab)
|
void ScInterpreter::PopSingleRef(SCCOL& rCol, SCROW &rRow, SCTAB& rTab)
|
||||||
{
|
{
|
||||||
if( sp )
|
ScAddress aAddr(rCol, rRow, rTab);
|
||||||
{
|
PopSingleRef(aAddr);
|
||||||
--sp;
|
rCol = aAddr.Col();
|
||||||
const FormulaToken* p = pStack[ sp ];
|
rRow = aAddr.Row();
|
||||||
switch (p->GetType())
|
rTab = aAddr.Tab();
|
||||||
{
|
|
||||||
case svError:
|
|
||||||
nGlobalError = p->GetError();
|
|
||||||
break;
|
|
||||||
case svSingleRef:
|
|
||||||
SingleRefToVars( *p->GetSingleRef(), rCol, rRow, rTab);
|
|
||||||
if (!pDok->m_TableOpList.empty())
|
|
||||||
ReplaceCell( rCol, rRow, rTab );
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
SetError( FormulaError::IllegalParameter);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
SetError( FormulaError::UnknownStackVariable);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScInterpreter::PopSingleRef( ScAddress& rAdr )
|
void ScInterpreter::PopSingleRef( ScAddress& rAdr )
|
||||||
|
Reference in New Issue
Block a user