Kaydet (Commit) 42d3adbc authored tarafından Michael Meeks's avatar Michael Meeks Kaydeden (comit) Kohei Yoshida

calm debug, and disable unless SC_FORMULAGROUP=1

Change-Id: I091d43dfa33f440edd50a1c937ef6e6f1930be4e
üst 20c4921e
...@@ -6224,6 +6224,9 @@ void Test::testCellTextWidth() ...@@ -6224,6 +6224,9 @@ void Test::testCellTextWidth()
void Test::testFormulaGrouping() void Test::testFormulaGrouping()
{ {
if ( !getenv("SC_FORMULAGROUP") )
return;
static const struct { static const struct {
const char *pFormula[3]; const char *pFormula[3];
const bool bGroup[3]; const bool bGroup[3];
......
...@@ -1748,7 +1748,7 @@ ScSimilarFormulaDelta *ScFormulaCell::BuildDeltaTo( ScFormulaCell *pOtherCell ) ...@@ -1748,7 +1748,7 @@ ScSimilarFormulaDelta *ScFormulaCell::BuildDeltaTo( ScFormulaCell *pOtherCell )
if ( !pThis || !pOther ) if ( !pThis || !pOther )
{ {
fprintf( stderr, "Error: no compiled code for cells !" ); // fprintf( stderr, "Error: no compiled code for cells !" );
return NULL; return NULL;
} }
...@@ -1817,12 +1817,12 @@ bool ScFormulaCell::InterpretFormulaGroup() ...@@ -1817,12 +1817,12 @@ bool ScFormulaCell::InterpretFormulaGroup()
if( !xGroup.get() ) if( !xGroup.get() )
return false; return false;
fprintf( stderr, "Interpret cell %d, %d\n", (int)aPos.Col(), (int)aPos.Row() ); // fprintf( stderr, "Interpret cell %d, %d\n", (int)aPos.Col(), (int)aPos.Row() );
if ( xGroup->mpDelta->IsInvariant() ) if ( xGroup->mpDelta->IsInvariant() )
{ {
fprintf( stderr, "struck gold - completely invariant for %d items !\n", // fprintf( stderr, "struck gold - completely invariant for %d items !\n",
(int)xGroup->mnLength ); // (int)xGroup->mnLength );
// calculate ourselves: // calculate ourselves:
InterpretTail( SCITP_NORMAL ); InterpretTail( SCITP_NORMAL );
......
...@@ -2119,7 +2119,7 @@ void ScColumn::RebuildFormulaGroups() ...@@ -2119,7 +2119,7 @@ void ScColumn::RebuildFormulaGroups()
} }
} }
#if 1 // OSL_DEBUG_LEVEL > 0 #if OSL_DEBUG_LEVEL > 0
if ( maDoubles.size() + maFnGroups.size() > 0 ) if ( maDoubles.size() + maFnGroups.size() > 0 )
{ {
rtl::OUString aStr; rtl::OUString aStr;
......
...@@ -697,6 +697,11 @@ void ScDocument::ApplyAsianEditSettings( ScEditEngineDefaulter& rEngine ) ...@@ -697,6 +697,11 @@ void ScDocument::ApplyAsianEditSettings( ScEditEngineDefaulter& rEngine )
void ScDocument::RebuildFormulaGroups() void ScDocument::RebuildFormulaGroups()
{ {
static const char *pEnableFormulaGroups = getenv("SC_FORMULAGROUP");
if ( !pEnableFormulaGroups )
return;
SCTAB nTab; SCTAB nTab;
for (nTab=0; nTab < static_cast<SCTAB>(maTabs.size()); nTab++) for (nTab=0; nTab < static_cast<SCTAB>(maTabs.size()); nTab++)
if (maTabs[nTab]) if (maTabs[nTab])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment