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 --- ucb/source/core/cmdenv.cxx | 2 +- ucb/source/core/ucb.cxx | 2 +- ucb/source/core/ucbprops.cxx | 2 +- ucb/source/core/ucbstore.cxx | 2 +- ucb/source/sorter/sortdynres.cxx | 2 +- ucb/source/ucp/cmis/cmis_provider.cxx | 2 +- ucb/source/ucp/ext/ucpext_provider.cxx | 2 +- ucb/source/ucp/ftp/ftpcontentprovider.cxx | 2 +- ucb/source/ucp/gio/gio_provider.cxx | 2 +- ucb/source/ucp/hierarchy/hierarchydatasource.cxx | 2 +- ucb/source/ucp/hierarchy/hierarchyprovider.cxx | 2 +- ucb/source/ucp/package/pkgprovider.cxx | 2 +- ucb/source/ucp/tdoc/tdoc_documentcontentfactory.cxx | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) (limited to 'ucb') diff --git a/ucb/source/core/cmdenv.cxx b/ucb/source/core/cmdenv.cxx index a768032f228d..0ea51438c920 100644 --- a/ucb/source/core/cmdenv.cxx +++ b/ucb/source/core/cmdenv.cxx @@ -111,7 +111,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_UcbCommandEnvironment_get_implementation( css::uno::XComponentContext* , css::uno::Sequence const&) { - return cppu::acquire(static_cast(new UcbCommandEnvironment())); + return cppu::acquire(new UcbCommandEnvironment()); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/ucb/source/core/ucb.cxx b/ucb/source/core/ucb.cxx index ddf575cd9d5f..a6d8817fae2c 100644 --- a/ucb/source/core/ucb.cxx +++ b/ucb/source/core/ucb.cxx @@ -302,7 +302,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_UniversalContentBroker_get_implementation( css::uno::XComponentContext* context , css::uno::Sequence const&) { - return cppu::acquire(static_cast(new UniversalContentBroker(context))); + return cppu::acquire(new UniversalContentBroker(context)); } diff --git a/ucb/source/core/ucbprops.cxx b/ucb/source/core/ucbprops.cxx index 95d9d90e6c36..604b8983bc42 100644 --- a/ucb/source/core/ucbprops.cxx +++ b/ucb/source/core/ucbprops.cxx @@ -216,7 +216,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_UcbPropertiesManager_get_implementation( css::uno::XComponentContext* , css::uno::Sequence const&) { - return cppu::acquire(static_cast(new UcbPropertiesManager())); + return cppu::acquire(new UcbPropertiesManager()); } // XPropertySetInfo methods. diff --git a/ucb/source/core/ucbstore.cxx b/ucb/source/core/ucbstore.cxx index d20378247fbd..bf86eba5fefc 100644 --- a/ucb/source/core/ucbstore.cxx +++ b/ucb/source/core/ucbstore.cxx @@ -176,7 +176,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_UcbStore_get_implementation( css::uno::XComponentContext* context , css::uno::Sequence const&) { - return cppu::acquire(static_cast(new UcbStore(context))); + return cppu::acquire(new UcbStore(context)); } diff --git a/ucb/source/sorter/sortdynres.cxx b/ucb/source/sorter/sortdynres.cxx index 437919e269da..5dc7694e107e 100644 --- a/ucb/source/sorter/sortdynres.cxx +++ b/ucb/source/sorter/sortdynres.cxx @@ -437,7 +437,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_SortedDynamicResultSetFactory_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new SortedDynamicResultSetFactory(context))); + return cppu::acquire(new SortedDynamicResultSetFactory(context)); } // SortedDynamicResultSetFactory methods. diff --git a/ucb/source/ucp/cmis/cmis_provider.cxx b/ucb/source/ucp/cmis/cmis_provider.cxx index bb84412bb97e..ded4483ecdfd 100644 --- a/ucb/source/ucp/cmis/cmis_provider.cxx +++ b/ucb/source/ucp/cmis/cmis_provider.cxx @@ -137,7 +137,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_cmis_ContentProvider_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new cmis::ContentProvider(context))); + return cppu::acquire(new cmis::ContentProvider(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/ucb/source/ucp/ext/ucpext_provider.cxx b/ucb/source/ucp/ext/ucpext_provider.cxx index d0a7993fbbf8..3befadd28a81 100644 --- a/ucb/source/ucp/ext/ucpext_provider.cxx +++ b/ucb/source/ucp/ext/ucpext_provider.cxx @@ -165,7 +165,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_ext_ContentProvider_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new ucb::ucp::ext::ContentProvider(context))); + return cppu::acquire(new ucb::ucp::ext::ContentProvider(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/ucb/source/ucp/ftp/ftpcontentprovider.cxx b/ucb/source/ucp/ftp/ftpcontentprovider.cxx index 9af1b97441e2..895711e0cfb4 100644 --- a/ucb/source/ucp/ftp/ftpcontentprovider.cxx +++ b/ucb/source/ucp/ftp/ftpcontentprovider.cxx @@ -239,7 +239,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_ftp_FTPContentProvider_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new FTPContentProvider(context))); + return cppu::acquire(new FTPContentProvider(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/ucb/source/ucp/gio/gio_provider.cxx b/ucb/source/ucp/gio/gio_provider.cxx index 4ac5ae6fffa6..3472fcfdf609 100644 --- a/ucb/source/ucp/gio/gio_provider.cxx +++ b/ucb/source/ucp/gio/gio_provider.cxx @@ -133,7 +133,7 @@ ucb_gio_ContentProvider_get_implementation( #if !GLIB_CHECK_VERSION(2,36,0) g_type_init(); #endif - return cppu::acquire(static_cast(new gio::ContentProvider(context))); + return cppu::acquire(new gio::ContentProvider(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/ucb/source/ucp/hierarchy/hierarchydatasource.cxx b/ucb/source/ucp/hierarchy/hierarchydatasource.cxx index 04162051b46e..cfd4c5e500e5 100644 --- a/ucb/source/ucp/hierarchy/hierarchydatasource.cxx +++ b/ucb/source/ucp/hierarchy/hierarchydatasource.cxx @@ -212,7 +212,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_HierarchyDataSource_get_implementation( css::uno::XComponentContext* context , css::uno::Sequence const&) { - return cppu::acquire(static_cast(new HierarchyDataSource(context))); + return cppu::acquire(new HierarchyDataSource(context)); } diff --git a/ucb/source/ucp/hierarchy/hierarchyprovider.cxx b/ucb/source/ucp/hierarchy/hierarchyprovider.cxx index 4922802f55fd..c6ca49541d90 100644 --- a/ucb/source/ucp/hierarchy/hierarchyprovider.cxx +++ b/ucb/source/ucp/hierarchy/hierarchyprovider.cxx @@ -116,7 +116,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_HierarchyContentProvider_get_implementation( css::uno::XComponentContext* context , css::uno::Sequence const&) { - return cppu::acquire(static_cast(new HierarchyContentProvider(context))); + return cppu::acquire(new HierarchyContentProvider(context)); } // XContentProvider methods. diff --git a/ucb/source/ucp/package/pkgprovider.cxx b/ucb/source/ucp/package/pkgprovider.cxx index 40ab9f635210..097eb09d44f3 100644 --- a/ucb/source/ucp/package/pkgprovider.cxx +++ b/ucb/source/ucp/package/pkgprovider.cxx @@ -266,7 +266,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_package_ContentProvider_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new ContentProvider(context))); + return cppu::acquire(new ContentProvider(context)); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/ucb/source/ucp/tdoc/tdoc_documentcontentfactory.cxx b/ucb/source/ucp/tdoc/tdoc_documentcontentfactory.cxx index 0b9252922160..84d59df3d378 100644 --- a/ucb/source/ucp/tdoc/tdoc_documentcontentfactory.cxx +++ b/ucb/source/ucp/tdoc/tdoc_documentcontentfactory.cxx @@ -109,7 +109,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface* ucb_tdoc_DocumentContentFactory_get_implementation( css::uno::XComponentContext* context, css::uno::Sequence const&) { - return cppu::acquire(static_cast(new DocumentContentFactory(context))); + return cppu::acquire(new DocumentContentFactory(context)); } -- cgit v1.2.3