[Libreoffice-commits] core.git: sw/source
Julien Nabet
serval2412 at yahoo.fr
Sun Nov 22 01:25:01 PST 2015
sw/source/core/bastyp/calc.cxx | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
New commits:
commit e110397a2816037b421bdcdeed0a2fdab5cd99d7
Author: Julien Nabet <serval2412 at yahoo.fr>
Date: Sun Nov 22 09:51:32 2015 +0100
tdf#95687: Wrong function names in Formula Writer are considered as SUM
New fix which deals with specific "foo" case
Change-Id: I479b30abf22315ddca6151cba220574029cb1a91
Reviewed-on: https://gerrit.libreoffice.org/20113
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Julien Nabet <serval2412 at yahoo.fr>
diff --git a/sw/source/core/bastyp/calc.cxx b/sw/source/core/bastyp/calc.cxx
index 1317ec2..d3bdf5d 100644
--- a/sw/source/core/bastyp/calc.cxx
+++ b/sw/source/core/bastyp/calc.cxx
@@ -713,7 +713,16 @@ SwCalcOper SwCalc::GetToken()
}
aVarName = aName;
eCurrOper = CALC_NAME;
- bSetError = false;
+ // Deal with specific "foo" case
+ if (sLowerCaseName.equals("foo"))
+ {
+ // "foo" function doesn't really exist but is sometimes used
+ // internally for setProperties method for example
+ // (see PythonTest_sw_python, set_expression)
+ bSetError = (sCommand.startsWith("foo("))?true:false;
+ }
+ else
+ bSetError = true;
}
else if ( aRes.TokenType & KParseType::DOUBLE_QUOTE_STRING )
{
More information about the Libreoffice-commits
mailing list