summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEike Rathke <erack@redhat.com>2017-12-05 19:59:09 +0100
committerEike Rathke <erack@redhat.com>2017-12-05 20:06:07 +0100
commitef6940a48097fee287a7d8782a6a208292f6926c (patch)
tree72cae1bf628688b8eb1aee200d50e23b5399783f
parent36493607d8da6a5caf4b73813ddbbf8dc1d7d895 (diff)
Save an unnecessary duplicate GetObject() call
Change-Id: Ib0efc84ad2cedc1a149fa57996bc0481bd64591b
-rw-r--r--basic/source/runtime/methods.cxx9
1 files changed, 3 insertions, 6 deletions
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx
index 2e8c0d4f2ca9..542c8817700c 100644
--- a/basic/source/runtime/methods.cxx
+++ b/basic/source/runtime/methods.cxx
@@ -3608,8 +3608,8 @@ OUString getObjectTypeName( SbxVariable* pVar )
OUString sRet( "Object" );
if ( pVar )
{
- SbxBase* pObj = pVar->GetObject();
- if( !pObj )
+ SbxBase* pBaseObj = pVar->GetObject();
+ if( !pBaseObj )
{
sRet = "Nothing";
}
@@ -3618,10 +3618,7 @@ OUString getObjectTypeName( SbxVariable* pVar )
SbUnoObject* pUnoObj = dynamic_cast<SbUnoObject*>( pVar );
if ( !pUnoObj )
{
- if ( SbxBase* pBaseObj = pVar->GetObject() )
- {
- pUnoObj = dynamic_cast<SbUnoObject*>( pBaseObj );
- }
+ pUnoObj = dynamic_cast<SbUnoObject*>( pBaseObj );
}
if ( pUnoObj )
{