[Libreoffice-commits] .: sc/inc sc/source

Eike Rathke erack at kemper.freedesktop.org
Wed Aug 24 19:10:34 PDT 2011


 sc/inc/formularesult.hxx         |    2 +-
 sc/source/core/tool/interpr4.cxx |    2 +-
 sc/source/core/tool/token.cxx    |    2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 61674465b74f60d7ddb2d7a0fa0e17c9990f6301
Author: Eike Rathke <erack at erack.de>
Date:   Thu Aug 25 04:03:12 2011 +0200

    use boost::intrusive_ptr::get() instead of operator->()
    
    Old intrusive pointer in operator->() simply returned a NULL pointer if
    so, boost::intrusive_ptr asserts on that. If explicitly used to obtain
    the pointer use get() instead.

diff --git a/sc/inc/formularesult.hxx b/sc/inc/formularesult.hxx
index 6405735..1cc5faf 100644
--- a/sc/inc/formularesult.hxx
+++ b/sc/inc/formularesult.hxx
@@ -407,7 +407,7 @@ inline bool ScFormulaResult::IsEmptyDisplayedAsString() const
         // don't need to test for mpToken here, GetType() already did it
         const ScEmptyCellToken* p = dynamic_cast<const ScEmptyCellToken*>(
                 static_cast<const ScMatrixCellResultToken*>(
-                    mpToken)->GetUpperLeftToken().operator->());
+                    mpToken)->GetUpperLeftToken().get());
         if (p)
             return p->IsDisplayedAsString();
     }
diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx
index 2f2d882..05ff646 100644
--- a/sc/source/core/tool/interpr4.cxx
+++ b/sc/source/core/tool/interpr4.cxx
@@ -4301,7 +4301,7 @@ StackVar ScInterpreter::Interpret()
     if (eType == svMatrix)
         // Results are immutable in case they would be reused as input for new
         // interpreters.
-        static_cast<ScToken*>(xResult.operator->())->GetMatrix()->SetImmutable( true);
+        static_cast<ScToken*>(xResult.get())->GetMatrix()->SetImmutable( true);
     return eType;
 }
 
diff --git a/sc/source/core/tool/token.cxx b/sc/source/core/tool/token.cxx
index c34a1ac..f0dc5cf 100644
--- a/sc/source/core/tool/token.cxx
+++ b/sc/source/core/tool/token.cxx
@@ -1041,7 +1041,7 @@ const ScMatrix* ScMatrixCellResultToken::GetMatrix() const  { return xMatrix.get
 // satisfy vtable linkage.
 ScMatrix* ScMatrixCellResultToken::GetMatrix()
 {
-    return const_cast<ScMatrix*>(xMatrix.operator->());
+    return const_cast<ScMatrix*>(xMatrix.get());
 }
 bool ScMatrixCellResultToken::operator==( const FormulaToken& r ) const
 {


More information about the Libreoffice-commits mailing list