diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2018-07-26 12:17:51 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2018-07-26 20:43:19 +0200 |
commit | ec32cb36e63fe3dd1599b2984ade83b811700939 (patch) | |
tree | 359b5e9dfe6bf4ea081abd1ad9af444b02cf129d /filter | |
parent | 0c457a20b1a7caa9e8631dfdaa4a41a5ee149e8d (diff) |
filter: 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: I20a2c713f0fea62659d44298c1d98dc9b7f2d5aa
Reviewed-on: https://gerrit.libreoffice.org/58076
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'filter')
-rw-r--r-- | filter/source/graphicfilter/icgm/bundles.cxx | 8 | ||||
-rw-r--r-- | filter/source/graphicfilter/icgm/bundles.hxx | 6 | ||||
-rw-r--r-- | filter/source/msfilter/svdfppt.cxx | 19 | ||||
-rw-r--r-- | filter/source/msfilter/util.cxx | 7 | ||||
-rw-r--r-- | filter/source/svg/svgexport.cxx | 5 |
5 files changed, 10 insertions, 35 deletions
diff --git a/filter/source/graphicfilter/icgm/bundles.cxx b/filter/source/graphicfilter/icgm/bundles.cxx index e3ced2b7153d..c083229216fa 100644 --- a/filter/source/graphicfilter/icgm/bundles.cxx +++ b/filter/source/graphicfilter/icgm/bundles.cxx @@ -23,14 +23,6 @@ #include <tools/stream.hxx> #include <memory> -Bundle& Bundle::operator=( const Bundle& rSource ) -{ - mnColor = rSource.mnColor; - mnBundleIndex = rSource.mnBundleIndex; - return *this; -}; - - void Bundle::SetColor( sal_uInt32 nColor ) { mnColor = nColor; diff --git a/filter/source/graphicfilter/icgm/bundles.hxx b/filter/source/graphicfilter/icgm/bundles.hxx index 40178e373f71..ba0740afdb45 100644 --- a/filter/source/graphicfilter/icgm/bundles.hxx +++ b/filter/source/graphicfilter/icgm/bundles.hxx @@ -45,9 +45,13 @@ public: {}; virtual Bundle* Clone() { return new Bundle( *this ); }; - Bundle& operator=(const Bundle& rBundle ); virtual ~Bundle() {} ; + + Bundle(Bundle const &) = default; + Bundle(Bundle &&) = default; + Bundle & operator =(Bundle const &) = default; + Bundle & operator =(Bundle &&) = default; }; diff --git a/filter/source/msfilter/svdfppt.cxx b/filter/source/msfilter/svdfppt.cxx index 02201e843ece..d31da869b523 100644 --- a/filter/source/msfilter/svdfppt.cxx +++ b/filter/source/msfilter/svdfppt.cxx @@ -3108,11 +3108,6 @@ HeaderFooterEntry::HeaderFooterEntry( const PptSlidePersistEntry* pMPE ) : } } -HeaderFooterEntry::~HeaderFooterEntry() -{ -} - - sal_uInt32 HeaderFooterEntry::IsToDisplay( sal_uInt32 nInstance ) { sal_uInt32 nMask = 0; @@ -3834,11 +3829,6 @@ PPTCharSheet::PPTCharSheet( TSS_Type nInstance ) } } -PPTCharSheet::PPTCharSheet( const PPTCharSheet& rAttr ) -{ - *this = rAttr; -} - void PPTCharSheet::Read( SvStream& rIn, sal_uInt32 nLevel) { // character attributes @@ -3931,11 +3921,6 @@ PPTParaSheet::PPTParaSheet( TSS_Type nInstance ) } } -PPTParaSheet::PPTParaSheet( const PPTParaSheet& rSheet ) -{ - *this = rSheet; -} - void PPTParaSheet::Read( SdrPowerPointImport const & #ifdef DBG_UTIL rManager @@ -4760,10 +4745,6 @@ PPTTextSpecInfo::PPTTextSpecInfo( sal_uInt32 _nCharIdx ) : nLanguage[ 2 ] = LANGUAGE_SYSTEM; } -PPTTextSpecInfo::~PPTTextSpecInfo() -{ -} - PPTTextSpecInfoAtomInterpreter::PPTTextSpecInfoAtomInterpreter() : bValid ( false ) { diff --git a/filter/source/msfilter/util.cxx b/filter/source/msfilter/util.cxx index fec841f2d34f..9335cc4d2b00 100644 --- a/filter/source/msfilter/util.cxx +++ b/filter/source/msfilter/util.cxx @@ -310,13 +310,6 @@ WW8ReadFieldParams::WW8ReadFieldParams( const OUString& _rData ) nSavPtr = nNext; } - -WW8ReadFieldParams::~WW8ReadFieldParams() -{ - -} - - OUString WW8ReadFieldParams::GetResult() const { if (nFnd<0 && nSavPtr>nFnd) diff --git a/filter/source/svg/svgexport.cxx b/filter/source/svg/svgexport.cxx index 91a1d35c3bb4..f959563de94d 100644 --- a/filter/source/svg/svgexport.cxx +++ b/filter/source/svg/svgexport.cxx @@ -100,6 +100,11 @@ class TextField protected: SVGFilter::ObjectSet mMasterPageSet; public: + TextField() = default; + TextField(TextField const &) = default; + TextField(TextField &&) = default; + TextField & operator =(TextField const &) = default; + TextField & operator =(TextField &&) = default; virtual OUString getClassName() const { |