summaryrefslogtreecommitdiff
path: root/sc/source/core/data
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2013-11-12 14:43:41 -0500
committerKohei Yoshida <kohei.yoshida@collabora.com>2013-11-12 18:51:38 -0500
commit177c0adede9ba4b34aa3f4a80cf7021e327c9d20 (patch)
treec5516dcffacb1f3c0cc087e1ef5671b9ff6f23c7 /sc/source/core/data
parenta621bdb0aad19a3a5ee4ff7089fca7cfe0ba1467 (diff)
Reduce the amount of RPM token generation.
Change-Id: I03941690114b17d8ab63cfb9b1b23a2ff1741b10
Diffstat (limited to 'sc/source/core/data')
-rw-r--r--sc/source/core/data/formulacell.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index 5e92efa27a5b..07f865681f66 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -3468,6 +3468,7 @@ public:
bool convert(ScTokenArray& rCode)
{
+#if 0
{ // debug to start with:
ScCompiler aComp( &mrDoc, mrPos, rCode);
aComp.SetGrammar(formula::FormulaGrammar::GRAM_NATIVE_XL_R1C1);
@@ -3475,6 +3476,7 @@ public:
aComp.CreateStringFromTokenArray(aAsString);
SAL_DEBUG("interpret formula: " << aAsString.makeStringAndClear());
}
+#endif
rCode.Reset();
for (const formula::FormulaToken* p = rCode.First(); p; p = rCode.Next())
@@ -3614,6 +3616,10 @@ public:
}
}
+ ScCompiler aComp(&mrDoc, mrPos, mrGroupTokens);
+ aComp.SetGrammar(mrDoc.GetGrammar());
+ aComp.CompileTokenArray(); // Regenerate RPN tokens.
+
return true;
}
};