From 96388e5e809a48573970df9b6b2649517a08447f Mon Sep 17 00:00:00 2001 From: Mike Kaganski Date: Wed, 10 Mar 2021 09:41:13 +0300 Subject: Drop 'static_cast' syntactic noise ... where the object is created in-place, and its type is known Change-Id: Ifabfcf2f3ad0d60152f14e8d970c1faa42115288 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112256 Tested-by: Jenkins Reviewed-by: Mike Kaganski --- embeddedobj/source/commonembedding/xfactory.cxx | 4 ++-- embeddedobj/source/general/xcreator.cxx | 2 +- embeddedobj/source/msole/xdialogcreator.cxx | 2 +- embeddedobj/source/msole/xolefactory.cxx | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) (limited to 'embeddedobj') diff --git a/embeddedobj/source/commonembedding/xfactory.cxx b/embeddedobj/source/commonembedding/xfactory.cxx index 3f7cb8fde98f..c6f57aa9c643 100644 --- a/embeddedobj/source/commonembedding/xfactory.cxx +++ b/embeddedobj/source/commonembedding/xfactory.cxx @@ -368,7 +368,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* embeddedobj_OOoEmbeddedObjectFactory_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new OOoEmbeddedObjectFactory(context))); + return cppu::acquire(new OOoEmbeddedObjectFactory(context)); } @@ -412,6 +412,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* embeddedobj_OOoSpecialEmbeddedObjectFactory_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new OOoSpecialEmbeddedObjectFactory(context))); + return cppu::acquire(new OOoSpecialEmbeddedObjectFactory(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/embeddedobj/source/general/xcreator.cxx b/embeddedobj/source/general/xcreator.cxx index a54295895190..d057aeba4a1a 100644 --- a/embeddedobj/source/general/xcreator.cxx +++ b/embeddedobj/source/general/xcreator.cxx @@ -410,7 +410,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* embeddedobj_UNOEmbeddedObjectCreator_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new UNOEmbeddedObjectCreator(context))); + return cppu::acquire(new UNOEmbeddedObjectCreator(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/embeddedobj/source/msole/xdialogcreator.cxx b/embeddedobj/source/msole/xdialogcreator.cxx index 2d162cf9608e..226528516953 100644 --- a/embeddedobj/source/msole/xdialogcreator.cxx +++ b/embeddedobj/source/msole/xdialogcreator.cxx @@ -329,7 +329,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* embeddedobj_MSOLEDialogObjectCreator_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new MSOLEDialogObjectCreator(context))); + return cppu::acquire(new MSOLEDialogObjectCreator(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/embeddedobj/source/msole/xolefactory.cxx b/embeddedobj/source/msole/xolefactory.cxx index b18ba1153498..1a7728ef8cdd 100644 --- a/embeddedobj/source/msole/xolefactory.cxx +++ b/embeddedobj/source/msole/xolefactory.cxx @@ -245,7 +245,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* embeddedobj_OleEmbeddedObjectFactory_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new OleEmbeddedObjectFactory(context))); + return cppu::acquire(new OleEmbeddedObjectFactory(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit