diff options
Diffstat (limited to 'sc/source/core/tool/interpr4.cxx')
-rw-r--r-- | sc/source/core/tool/interpr4.cxx | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx index 28ceba647ccf..27170ca94490 100644 --- a/sc/source/core/tool/interpr4.cxx +++ b/sc/source/core/tool/interpr4.cxx @@ -944,12 +944,9 @@ void ScInterpreter::DoubleRefToVars( const formula::FormulaToken* p, const ScComplexRefData& rCRef = *p->GetDoubleRef(); SingleRefToVars( rCRef.Ref1, rCol1, rRow1, rTab1); SingleRefToVars( rCRef.Ref2, rCol2, rRow2, rTab2); - if (rCol2 < rCol1) - std::swap( rCol2, rCol1); - if (rRow2 < rRow1) - std::swap( rRow2, rRow1); - if (rTab2 < rTab1) - std::swap( rTab2, rTab1); + PutInOrder(rCol1, rCol2); + PutInOrder(rRow1, rRow2); + PutInOrder(rTab1, rTab2); if (!mrDoc.m_TableOpList.empty()) { ScRange aRange( rCol1, rRow1, rTab1, rCol2, rRow2, rTab2 ); |