diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2018-07-26 16:21:18 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2018-07-27 08:29:15 +0200 |
commit | 13502c0f201f37960ec06bf1e7e2e8b4d838090a (patch) | |
tree | 036751c32e5aaaf29954cb54fbfa406b841316fd /include/svx/sxcllitm.hxx | |
parent | 6844ef8a7ed9b253b6cca4c8d8aec54ef05d013e (diff) |
svx: avoid -Werror=deprecated-copy (GCC trunk towards GCC 9)
...by explicitly defaulting the copy/move functions (and, where needed in turn,
also a default ctor) for classes that have a user-declared dtor that does
nothing other than an implicitly-defined one would do, but needs to be user-
declared because it is virtual and potentially serves as a key function to
emit the vtable, or is non-public, etc.; and by removing explicitly user-
provided functions that do the same as their implicitly-defined counterparts,
but may prevent implicitly declared copy functions from being defined as non-
deleted in the future. (Even if such a user-provided function was declared
non-inline in an include file, the apparently-used implicitly-defined copy
functions are already include, so why bother with non-inline functions.)
Change-Id: I1c470ef87e95b22e406099a4e6816693edab2e03
Reviewed-on: https://gerrit.libreoffice.org/58131
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'include/svx/sxcllitm.hxx')
-rw-r--r-- | include/svx/sxcllitm.hxx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/svx/sxcllitm.hxx b/include/svx/sxcllitm.hxx index 2b3dae33f370..8fa6eaf81285 100644 --- a/include/svx/sxcllitm.hxx +++ b/include/svx/sxcllitm.hxx @@ -33,6 +33,11 @@ public: SdrCaptionLineLenItem(long nLineLen=0): SdrMetricItem(SDRATTR_CAPTIONLINELEN,nLineLen) {} virtual ~SdrCaptionLineLenItem() override; virtual SfxPoolItem* Clone(SfxItemPool* pPool=nullptr) const override; + + SdrCaptionLineLenItem(SdrCaptionLineLenItem const &) = default; + SdrCaptionLineLenItem(SdrCaptionLineLenItem &&) = default; + SdrCaptionLineLenItem & operator =(SdrCaptionLineLenItem const &) = default; + SdrCaptionLineLenItem & operator =(SdrCaptionLineLenItem &&) = default; }; /** @@ -44,6 +49,11 @@ public: SdrCaptionFitLineLenItem(bool bBestFit=true): SdrYesNoItem(SDRATTR_CAPTIONFITLINELEN,bBestFit) {} virtual ~SdrCaptionFitLineLenItem() override; virtual SfxPoolItem* Clone(SfxItemPool* pPool=nullptr) const override; + + SdrCaptionFitLineLenItem(SdrCaptionFitLineLenItem const &) = default; + SdrCaptionFitLineLenItem(SdrCaptionFitLineLenItem &&) = default; + SdrCaptionFitLineLenItem & operator =(SdrCaptionFitLineLenItem const &) = default; + SdrCaptionFitLineLenItem & operator =(SdrCaptionFitLineLenItem &&) = default; }; #endif |