summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2016-04-05 18:03:00 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2016-04-12 14:05:33 +0000
commita4c6fc2c2641d2020cce626877749a22ca10be4b (patch)
tree09db4d41c26f3ef73c2dff69616e437a92dd0918
parent44d5d9fdb3f35ae09f7e9938609553cd3a4c4412 (diff)
Resolves: tdf#98990 accept R1C1 notation entire column/row references
... which consist of only C4 or C[3] without a range operator. Change-Id: I1865f0ec4c4fec1101b93b6b40d6f26871a65f07 (cherry picked from commit 3c36ba50f65d663f35264f2a11c99c0ff98674a2) Reviewed-on: https://gerrit.libreoffice.org/23842 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
-rw-r--r--sc/source/core/tool/compiler.cxx14
1 files changed, 9 insertions, 5 deletions
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index aa9e1b9bf896..5f258dfcc0d6 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -3008,15 +3008,19 @@ bool ScCompiler::IsReference( const OUString& rName )
}
else
{
- // Special treatment for the 'E:\[doc]Sheet1:Sheet3'!D5 Excel sickness,
- // mnRangeOpPosInSymbol did not catch the range operator as it is
- // within a quoted name.
switch (pConv->meConv)
{
case FormulaGrammar::CONV_XL_A1:
- case FormulaGrammar::CONV_XL_R1C1:
case FormulaGrammar::CONV_XL_OOX:
- if (rName[0] == '\'' && IsDoubleReference( rName))
+ // Special treatment for the 'E:\[doc]Sheet1:Sheet3'!D5 Excel
+ // sickness, mnRangeOpPosInSymbol did not catch the range
+ // operator as it is within a quoted name.
+ if (rName[0] != '\'')
+ return false; // Document name has to be single quoted.
+ // fallthru
+ case FormulaGrammar::CONV_XL_R1C1:
+ // C2 or C[1] are valid entire column references.
+ if (IsDoubleReference( rName))
return true;
break;
default: