diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-01-26 12:28:58 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-01-26 12:54:43 +0000 |
commit | e57ca02849c3d87142ff5ff9099a212e72b8139c (patch) | |
tree | bcce66b27261553c308779f3e8663a269ed3a671 /hwpfilter | |
parent | 8802ebd5172ec4bc412a59d136c82b77ab452281 (diff) |
Remove dynamic exception specifications
...(for now, from LIBO_INTERNAL_CODE only). See the mail thread starting at
<https://lists.freedesktop.org/archives/libreoffice/2017-January/076665.html>
"Dynamic Exception Specifications" for details.
Most changes have been done automatically by the rewriting loplugin:dynexcspec
(after enabling the rewriting mode, to be committed shortly). The way it only
removes exception specs from declarations if it also sees a definition, it
identified some dead declarations-w/o-definitions (that have been removed
manually) and some cases where a definition appeared in multiple include files
(which have also been cleaned up manually). There's also been cases of macro
paramters (that were used to abstract over exception specs) that have become
unused now (and been removed).
Furthermore, some code needed to be cleaned up manually
(avmedia/source/quicktime/ and connectivity/source/drivers/kab/), as I had no
configurations available that would actually build that code. Missing @throws
documentation has not been applied in such manual clean-up.
Change-Id: I3408691256c9b0c12bc5332de976743626e13960
Reviewed-on: https://gerrit.libreoffice.org/33574
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'hwpfilter')
-rw-r--r-- | hwpfilter/source/attributes.cxx | 12 | ||||
-rw-r--r-- | hwpfilter/source/attributes.hxx | 12 | ||||
-rw-r--r-- | hwpfilter/source/hwpreader.cxx | 2 | ||||
-rw-r--r-- | hwpfilter/source/hwpreader.hxx | 34 |
4 files changed, 28 insertions, 32 deletions
diff --git a/hwpfilter/source/attributes.cxx b/hwpfilter/source/attributes.cxx index c3683138f14c..a59850e51fca 100644 --- a/hwpfilter/source/attributes.cxx +++ b/hwpfilter/source/attributes.cxx @@ -46,7 +46,7 @@ struct AttributeListImpl_impl std::vector<struct TagAttribute> vecAttribute; }; -sal_Int16 SAL_CALL AttributeListImpl::getLength() throw (RuntimeException, std::exception) +sal_Int16 SAL_CALL AttributeListImpl::getLength() { return (sal_Int16)m_pImpl->vecAttribute.size(); } @@ -60,7 +60,7 @@ AttributeListImpl::AttributeListImpl( const AttributeListImpl &r ) } -OUString AttributeListImpl::getNameByIndex(sal_Int16 i) throw (RuntimeException, std::exception) +OUString AttributeListImpl::getNameByIndex(sal_Int16 i) { sal_uInt32 i2 = sal::static_int_cast<sal_Int16>(i); if( i >= 0 && i2 < m_pImpl->vecAttribute.size() ) @@ -71,7 +71,7 @@ OUString AttributeListImpl::getNameByIndex(sal_Int16 i) throw (RuntimeException, } -OUString AttributeListImpl::getTypeByIndex(sal_Int16 i) throw (RuntimeException, std::exception) +OUString AttributeListImpl::getTypeByIndex(sal_Int16 i) { sal_uInt32 i2 = sal::static_int_cast<sal_Int16>(i); if( i >= 0 && i2 < m_pImpl->vecAttribute.size() ) @@ -82,7 +82,7 @@ OUString AttributeListImpl::getTypeByIndex(sal_Int16 i) throw (RuntimeException, } -OUString AttributeListImpl::getValueByIndex(sal_Int16 i) throw (RuntimeException, std::exception) +OUString AttributeListImpl::getValueByIndex(sal_Int16 i) { sal_uInt32 i2 = sal::static_int_cast<sal_Int16>(i); if( i >= 0 && i2 < m_pImpl->vecAttribute.size() ) @@ -94,7 +94,7 @@ OUString AttributeListImpl::getValueByIndex(sal_Int16 i) throw (RuntimeException } -OUString AttributeListImpl::getTypeByName( const OUString& sName ) throw (RuntimeException, std::exception) +OUString AttributeListImpl::getTypeByName( const OUString& sName ) { std::vector<struct TagAttribute>::iterator ii = m_pImpl->vecAttribute.begin(); @@ -109,7 +109,7 @@ OUString AttributeListImpl::getTypeByName( const OUString& sName ) throw (Runtim } -OUString AttributeListImpl::getValueByName(const OUString& sName) throw (RuntimeException, std::exception) +OUString AttributeListImpl::getValueByName(const OUString& sName) { std::vector<struct TagAttribute>::iterator ii = m_pImpl->vecAttribute.begin(); diff --git a/hwpfilter/source/attributes.hxx b/hwpfilter/source/attributes.hxx index 8d4c0cdce768..09dc26a03b1f 100644 --- a/hwpfilter/source/attributes.hxx +++ b/hwpfilter/source/attributes.hxx @@ -40,12 +40,12 @@ public: AttributeListImpl( const AttributeListImpl & ); public: - virtual sal_Int16 SAL_CALL getLength() throw (RuntimeException, std::exception) override; - virtual OUString SAL_CALL getNameByIndex(sal_Int16 i) throw (RuntimeException, std::exception) override; - virtual OUString SAL_CALL getTypeByIndex(sal_Int16 i) throw (RuntimeException, std::exception) override; - virtual OUString SAL_CALL getTypeByName(const OUString& aName) throw (RuntimeException, std::exception) override; - virtual OUString SAL_CALL getValueByIndex(sal_Int16 i) throw (RuntimeException, std::exception) override; - virtual OUString SAL_CALL getValueByName(const OUString& aName) throw (RuntimeException, std::exception) override; + virtual sal_Int16 SAL_CALL getLength() override; + virtual OUString SAL_CALL getNameByIndex(sal_Int16 i) override; + virtual OUString SAL_CALL getTypeByIndex(sal_Int16 i) override; + virtual OUString SAL_CALL getTypeByName(const OUString& aName) override; + virtual OUString SAL_CALL getValueByIndex(sal_Int16 i) override; + virtual OUString SAL_CALL getValueByName(const OUString& aName) override; public: void addAttribute( const OUString &sName , const OUString &sType , const OUString &sValue ); diff --git a/hwpfilter/source/hwpreader.cxx b/hwpfilter/source/hwpreader.cxx index 68388d12b3c4..deb3b267805d 100644 --- a/hwpfilter/source/hwpreader.cxx +++ b/hwpfilter/source/hwpreader.cxx @@ -137,7 +137,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT bool SAL_CALL TestImportHWP(const OUString &rURL return true; } -sal_Bool HwpReader::filter(const Sequence< PropertyValue >& rDescriptor) throw(RuntimeException, std::exception) +sal_Bool HwpReader::filter(const Sequence< PropertyValue >& rDescriptor) { utl::MediaDescriptor aDescriptor(rDescriptor); aDescriptor.addInputStream(); diff --git a/hwpfilter/source/hwpreader.hxx b/hwpfilter/source/hwpreader.hxx index c44a0c37abd6..a0c7d0d8c0ee 100644 --- a/hwpfilter/source/hwpreader.hxx +++ b/hwpfilter/source/hwpreader.hxx @@ -84,8 +84,8 @@ public: /** * parseStream does Parser-startup initializations */ - virtual sal_Bool SAL_CALL filter(const Sequence< PropertyValue >& aDescriptor) throw (RuntimeException, std::exception) override; - virtual void SAL_CALL cancel() throw(RuntimeException, std::exception) override {} + virtual sal_Bool SAL_CALL filter(const Sequence< PropertyValue >& aDescriptor) override; + virtual void SAL_CALL cancel() override {} void SAL_CALL setDocumentHandler(Reference< XDocumentHandler > const & xHandler) { m_rxDocumentHandler = xHandler; @@ -162,21 +162,19 @@ public: public: // XFilter - virtual sal_Bool SAL_CALL filter( const Sequence< PropertyValue >& aDescriptor ) - throw( RuntimeException, std::exception ) override; - virtual void SAL_CALL cancel() throw(RuntimeException, std::exception) override; + virtual sal_Bool SAL_CALL filter( const Sequence< PropertyValue >& aDescriptor ) override; + virtual void SAL_CALL cancel() override; // XImporter - virtual void SAL_CALL setTargetDocument( const Reference< XComponent >& xDoc) - throw( IllegalArgumentException, RuntimeException, std::exception ) override; + virtual void SAL_CALL setTargetDocument( const Reference< XComponent >& xDoc) override; // XServiceInfo - OUString SAL_CALL getImplementationName() throw (RuntimeException, std::exception) override; - Sequence< OUString > SAL_CALL getSupportedServiceNames() throw (css::uno::RuntimeException, std::exception) override; - sal_Bool SAL_CALL supportsService(const OUString& ServiceName) throw (css::uno::RuntimeException, std::exception) override; + OUString SAL_CALL getImplementationName() override; + Sequence< OUString > SAL_CALL getSupportedServiceNames() override; + sal_Bool SAL_CALL supportsService(const OUString& ServiceName) override; //XExtendedFilterDetection - virtual OUString SAL_CALL detect( css::uno::Sequence< css::beans::PropertyValue >& rDescriptor ) throw (css::uno::RuntimeException, std::exception) override; + virtual OUString SAL_CALL detect( css::uno::Sequence< css::beans::PropertyValue >& rDescriptor ) override; public: Reference< XFilter > rFilter; @@ -185,7 +183,7 @@ public: /// @throws Exception Reference< XInterface > HwpImportFilter_CreateInstance( - const Reference< XMultiServiceFactory >& rSMgr ) throw( Exception ) + const Reference< XMultiServiceFactory >& rSMgr ) { HwpImportFilter *p = new HwpImportFilter( rSMgr ); @@ -224,19 +222,17 @@ HwpImportFilter::~HwpImportFilter() } sal_Bool HwpImportFilter::filter( const Sequence< PropertyValue >& aDescriptor ) - throw( RuntimeException, std::exception ) { // delegate to IchitaroImpoter return rFilter->filter( aDescriptor ); } -void HwpImportFilter::cancel() throw(css::uno::RuntimeException, std::exception) +void HwpImportFilter::cancel() { rFilter->cancel(); } void HwpImportFilter::setTargetDocument( const Reference< XComponent >& xDoc ) - throw( IllegalArgumentException, RuntimeException, std::exception ) { // delegate rImporter->setTargetDocument( xDoc ); @@ -247,18 +243,18 @@ OUString HwpImportFilter::getImplementationName_Static() throw() return OUString( IMPLEMENTATION_NAME ); } -OUString HwpImportFilter::getImplementationName() throw(css::uno::RuntimeException, std::exception) +OUString HwpImportFilter::getImplementationName() { return OUString( IMPLEMENTATION_NAME ); } -sal_Bool HwpImportFilter::supportsService( const OUString& ServiceName ) throw(css::uno::RuntimeException, std::exception) +sal_Bool HwpImportFilter::supportsService( const OUString& ServiceName ) { return cppu::supportsService(this, ServiceName); } //XExtendedFilterDetection -OUString HwpImportFilter::detect( css::uno::Sequence< css::beans::PropertyValue >& rDescriptor ) throw (css::uno::RuntimeException, std::exception) +OUString HwpImportFilter::detect( css::uno::Sequence< css::beans::PropertyValue >& rDescriptor ) { OUString sTypeName; @@ -284,7 +280,7 @@ OUString HwpImportFilter::detect( css::uno::Sequence< css::beans::PropertyValue return sTypeName; } -Sequence< OUString> HwpImportFilter::getSupportedServiceNames() throw(css::uno::RuntimeException, std::exception) +Sequence< OUString> HwpImportFilter::getSupportedServiceNames() { Sequence < OUString > aRet(2); OUString* pArray = aRet.getArray(); |