diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-04-30 08:20:03 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-05-02 17:02:28 +0200 |
commit | 10d29c390dd58ed629dd27fe5ed35fae28eceec3 (patch) | |
tree | 7476cbb90fff182c5bec0a5a1ef9c41a3ad29f19 /sfx2/source | |
parent | a9243e626193ab4efe3a618413886773336a38e6 (diff) |
throw() -> noexcept, part 2/3: Automatic loplugin:noexcept rewrite
Change-Id: I076f16d0536b534abf0ced4d76051eadb4c0e033
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/114949
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sfx2/source')
-rw-r--r-- | sfx2/source/control/thumbnailviewacc.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/control/thumbnailviewacc.hxx | 4 | ||||
-rw-r--r-- | sfx2/source/dialog/backingcomp.cxx | 8 | ||||
-rw-r--r-- | sfx2/source/doc/SfxDocumentMetaData.cxx | 20 | ||||
-rw-r--r-- | sfx2/source/doc/docundomanager.cxx | 4 | ||||
-rw-r--r-- | sfx2/source/inc/docundomanager.hxx | 4 | ||||
-rw-r--r-- | sfx2/source/statbar/stbitem.cxx | 4 |
7 files changed, 24 insertions, 24 deletions
diff --git a/sfx2/source/control/thumbnailviewacc.cxx b/sfx2/source/control/thumbnailviewacc.cxx index a8cbe92d33c1..e723ad9efe31 100644 --- a/sfx2/source/control/thumbnailviewacc.cxx +++ b/sfx2/source/control/thumbnailviewacc.cxx @@ -53,7 +53,7 @@ const uno::Sequence< sal_Int8 >& ThumbnailViewAcc::getUnoTunnelId() } ThumbnailViewAcc* ThumbnailViewAcc::getImplementation( const uno::Reference< uno::XInterface >& rxData ) - throw() + noexcept { try { @@ -553,7 +553,7 @@ const uno::Sequence< sal_Int8 >& ThumbnailViewItemAcc::getUnoTunnelId() } ThumbnailViewItemAcc* ThumbnailViewItemAcc::getImplementation( const uno::Reference< uno::XInterface >& rxData ) - throw() + noexcept { try { diff --git a/sfx2/source/control/thumbnailviewacc.hxx b/sfx2/source/control/thumbnailviewacc.hxx index 2a56fa16b36a..48c7d70bb79c 100644 --- a/sfx2/source/control/thumbnailviewacc.hxx +++ b/sfx2/source/control/thumbnailviewacc.hxx @@ -62,7 +62,7 @@ public: bool HasAccessibleListeners() const { return( mxEventListeners.size() > 0 ); } - static ThumbnailViewAcc* getImplementation( const css::uno::Reference< css::uno::XInterface >& rxData ) throw(); + static ThumbnailViewAcc* getImplementation( const css::uno::Reference< css::uno::XInterface >& rxData ) noexcept; public: /** Called by the corresponding ValueSet when it gets the focus. @@ -175,7 +175,7 @@ public: void ParentDestroyed(); - static ThumbnailViewItemAcc* getImplementation( const css::uno::Reference< css::uno::XInterface >& rxData ) throw(); + static ThumbnailViewItemAcc* getImplementation( const css::uno::Reference< css::uno::XInterface >& rxData ) noexcept; public: diff --git a/sfx2/source/dialog/backingcomp.cxx b/sfx2/source/dialog/backingcomp.cxx index c748727fb4f4..8863a752ed45 100644 --- a/sfx2/source/dialog/backingcomp.cxx +++ b/sfx2/source/dialog/backingcomp.cxx @@ -82,8 +82,8 @@ public: // XInterface virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type& aType ) override; - virtual void SAL_CALL acquire ( ) throw( ) override; - virtual void SAL_CALL release ( ) throw( ) override; + virtual void SAL_CALL acquire ( ) noexcept override; + virtual void SAL_CALL release ( ) noexcept override; // XTypeProvide virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes () override; @@ -186,7 +186,7 @@ css::uno::Any SAL_CALL BackingComp::queryInterface( /*IN*/ const css::uno::Type& */ void SAL_CALL BackingComp::acquire() - throw() + noexcept { OWeakObject::acquire(); } @@ -196,7 +196,7 @@ void SAL_CALL BackingComp::acquire() */ void SAL_CALL BackingComp::release() - throw() + noexcept { OWeakObject::release(); } diff --git a/sfx2/source/doc/SfxDocumentMetaData.cxx b/sfx2/source/doc/SfxDocumentMetaData.cxx index a02010e0b3a7..fd31efd621a9 100644 --- a/sfx2/source/doc/SfxDocumentMetaData.cxx +++ b/sfx2/source/doc/SfxDocumentMetaData.cxx @@ -435,7 +435,7 @@ getQualifier(const char* i_name) { // get namespace for standard qualified names // NB: only call this with statically known strings! -OUString getNameSpace(const char* i_qname) throw () +OUString getNameSpace(const char* i_qname) noexcept { assert(i_qname); OUString ns; @@ -451,7 +451,7 @@ OUString getNameSpace(const char* i_qname) throw () bool textToDateOrDateTime(css::util::Date & io_rd, css::util::DateTime & io_rdt, bool & o_rIsDateTime, std::optional<sal_Int16> & o_rTimeZone, - const OUString& i_text) throw () + const OUString& i_text) noexcept { if (::sax::Converter::parseDateOrDateTime( &io_rd, io_rdt, o_rIsDateTime, &o_rTimeZone, i_text)) { @@ -464,7 +464,7 @@ textToDateOrDateTime(css::util::Date & io_rd, css::util::DateTime & io_rdt, // convert string to date/time bool -textToDateTime(css::util::DateTime & io_rdt, const OUString& i_text) throw () +textToDateTime(css::util::DateTime & io_rdt, const OUString& i_text) noexcept { if (::sax::Converter::parseDateTime(io_rdt, i_text)) { return true; @@ -476,7 +476,7 @@ textToDateTime(css::util::DateTime & io_rdt, const OUString& i_text) throw () // convert string to date/time with default return value css::util::DateTime -textToDateTimeDefault(const OUString& i_text) throw () +textToDateTimeDefault(const OUString& i_text) noexcept { css::util::DateTime dt; static_cast<void> (textToDateTime(dt, i_text)); @@ -487,7 +487,7 @@ textToDateTimeDefault(const OUString& i_text) throw () // convert date to string OUString dateToText(css::util::Date const& i_rd, - sal_Int16 const*const pTimeZone) throw () + sal_Int16 const*const pTimeZone) noexcept { if (isValidDate(i_rd)) { OUStringBuffer buf; @@ -502,7 +502,7 @@ dateToText(css::util::Date const& i_rd, // convert date/time to string OUString dateTimeToText(css::util::DateTime const& i_rdt, - sal_Int16 const*const pTimeZone = nullptr) throw () + sal_Int16 const*const pTimeZone = nullptr) noexcept { if (isValidDateTime(i_rdt)) { OUStringBuffer buf(32); @@ -516,7 +516,7 @@ dateTimeToText(css::util::DateTime const& i_rdt, // convert string to duration bool textToDuration(css::util::Duration& io_rDur, OUString const& i_rText) -throw () +noexcept { if (::sax::Converter::convertDuration(io_rDur, i_rText)) { return true; @@ -526,7 +526,7 @@ throw () } } -sal_Int32 textToDuration(OUString const& i_rText) throw () +sal_Int32 textToDuration(OUString const& i_rText) noexcept { css::util::Duration d; if (textToDuration(d, i_rText)) { @@ -540,7 +540,7 @@ sal_Int32 textToDuration(OUString const& i_rText) throw () } // convert duration to string -OUString durationToText(css::util::Duration const& i_rDur) throw () +OUString durationToText(css::util::Duration const& i_rDur) noexcept { OUStringBuffer buf; ::sax::Converter::convertDuration(buf, i_rDur); @@ -548,7 +548,7 @@ OUString durationToText(css::util::Duration const& i_rDur) throw () } // convert duration to string -OUString durationToText(sal_Int32 i_value) throw () +OUString durationToText(sal_Int32 i_value) noexcept { css::util::Duration ud; ud.Days = static_cast<sal_Int16>(i_value / (24 * 3600)); diff --git a/sfx2/source/doc/docundomanager.cxx b/sfx2/source/doc/docundomanager.cxx index 47da49774c4d..45102c961c99 100644 --- a/sfx2/source/doc/docundomanager.cxx +++ b/sfx2/source/doc/docundomanager.cxx @@ -224,14 +224,14 @@ namespace sfx2 } - void SAL_CALL DocumentUndoManager::acquire() throw() + void SAL_CALL DocumentUndoManager::acquire() noexcept { OWeakObject::acquire(); SfxModelSubComponent::acquireModel(); } - void SAL_CALL DocumentUndoManager::release() throw() + void SAL_CALL DocumentUndoManager::release() noexcept { SfxModelSubComponent::releaseModel(); OWeakObject::release(); diff --git a/sfx2/source/inc/docundomanager.hxx b/sfx2/source/inc/docundomanager.hxx index ce38680e264f..9145e5967d51 100644 --- a/sfx2/source/inc/docundomanager.hxx +++ b/sfx2/source/inc/docundomanager.hxx @@ -115,8 +115,8 @@ namespace sfx2 bool isInContext() const; // XInterface - virtual void SAL_CALL acquire( ) throw () override; - virtual void SAL_CALL release( ) throw () override; + virtual void SAL_CALL acquire( ) noexcept override; + virtual void SAL_CALL release( ) noexcept override; // XUndoManager virtual void SAL_CALL enterUndoContext( const OUString& i_title ) override; diff --git a/sfx2/source/statbar/stbitem.cxx b/sfx2/source/statbar/stbitem.cxx index 10807c70a26d..b5f37270e9d9 100644 --- a/sfx2/source/statbar/stbitem.cxx +++ b/sfx2/source/statbar/stbitem.cxx @@ -158,12 +158,12 @@ SfxStatusBarControl::~SfxStatusBarControl() // XInterface -void SAL_CALL SfxStatusBarControl::acquire() throw() +void SAL_CALL SfxStatusBarControl::acquire() noexcept { OWeakObject::acquire(); } -void SAL_CALL SfxStatusBarControl::release() throw() +void SAL_CALL SfxStatusBarControl::release() noexcept { OWeakObject::release(); } |