From a6c7b262212d56a4ad37e6475f96152296ab1d0c Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 14 Dec 2017 21:44:40 +0100 Subject: remove pointless APT_PURE from void functions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Earlier gcc versions used to complain that you should add them althrough there isn't a lot of point to it if you think about it, but now gcc (>= 8) complains about the attribute being present. warning: ‘pure’ attribute on function returning ‘void’ [-Wattributes] Reported-By: gcc -Wattributes Gbp-Dch: Ignore --- apt-pkg/acquire-item.cc | 2 +- apt-pkg/acquire.cc | 6 +++--- apt-pkg/cachefilter.cc | 4 ++-- apt-pkg/cacheset.cc | 10 +++++----- apt-pkg/clean.cc | 2 +- apt-pkg/indexcopy.cc | 10 +++++----- apt-pkg/indexfile.cc | 6 +++--- apt-pkg/install-progress.cc | 4 ++-- 8 files changed, 22 insertions(+), 22 deletions(-) (limited to 'apt-pkg') diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc index dc45a6acd..9b163081b 100644 --- a/apt-pkg/acquire-item.cc +++ b/apt-pkg/acquire-item.cc @@ -766,7 +766,7 @@ std::string pkgAcquire::Item::ShortDesc() const /*{{{*/ return DescURI(); } /*}}}*/ -APT_PURE void pkgAcquire::Item::Finished() /*{{{*/ +void pkgAcquire::Item::Finished() /*{{{*/ { } /*}}}*/ diff --git a/apt-pkg/acquire.cc b/apt-pkg/acquire.cc index f6e323d30..aabcb0aba 100644 --- a/apt-pkg/acquire.cc +++ b/apt-pkg/acquire.cc @@ -1431,6 +1431,6 @@ pkgAcquire::UriIterator::UriIterator(pkgAcquire::Queue *Q) : d(NULL), CurQ(Q), C } } -APT_PURE pkgAcquire::UriIterator::~UriIterator() {} -APT_PURE pkgAcquire::MethodConfig::~MethodConfig() {} -APT_PURE pkgAcquireStatus::~pkgAcquireStatus() {} +pkgAcquire::UriIterator::~UriIterator() {} +pkgAcquire::MethodConfig::~MethodConfig() {} +pkgAcquireStatus::~pkgAcquireStatus() {} diff --git a/apt-pkg/cachefilter.cc b/apt-pkg/cachefilter.cc index c49f5dfd0..eadbb98c7 100644 --- a/apt-pkg/cachefilter.cc +++ b/apt-pkg/cachefilter.cc @@ -27,8 +27,8 @@ namespace APT { APT_HIDDEN std::unordered_map> ArchToTupleMap; namespace CacheFilter { -APT_PURE Matcher::~Matcher() {} -APT_PURE PackageMatcher::~PackageMatcher() {} +Matcher::~Matcher() {} +PackageMatcher::~PackageMatcher() {} // Name matches RegEx /*{{{*/ PackageNameMatchesRegEx::PackageNameMatchesRegEx(std::string const &Pattern) { diff --git a/apt-pkg/cacheset.cc b/apt-pkg/cacheset.cc index a6570c95b..670cdba3a 100644 --- a/apt-pkg/cacheset.cc +++ b/apt-pkg/cacheset.cc @@ -737,7 +737,7 @@ void CacheSetHelper::canNotFindRegEx(PackageContainerInterface * const /*pci*/, } /*}}}*/ // canNotFindPackage - handle the case no package is found from a string/*{{{*/ -APT_PURE void CacheSetHelper::canNotFindPackage(PackageContainerInterface * const /*pci*/, pkgCacheFile &/*Cache*/, std::string const &/*str*/) { +void CacheSetHelper::canNotFindPackage(PackageContainerInterface * const /*pci*/, pkgCacheFile &/*Cache*/, std::string const &/*str*/) { } /*}}}*/ /*}}}*/ @@ -863,17 +863,17 @@ APT_IGNORE_DEPRECATED_POP } } // showTaskSelection /*{{{*/ -APT_PURE void CacheSetHelper::showTaskSelection(pkgCache::PkgIterator const &/*pkg*/, +void CacheSetHelper::showTaskSelection(pkgCache::PkgIterator const &/*pkg*/, std::string const &/*pattern*/) { } /*}}}*/ // showRegExSelection /*{{{*/ -APT_PURE void CacheSetHelper::showRegExSelection(pkgCache::PkgIterator const &/*pkg*/, +void CacheSetHelper::showRegExSelection(pkgCache::PkgIterator const &/*pkg*/, std::string const &/*pattern*/) { } /*}}}*/ // showFnmatchSelection /*{{{*/ -APT_PURE void CacheSetHelper::showFnmatchSelection(pkgCache::PkgIterator const &/*pkg*/, +void CacheSetHelper::showFnmatchSelection(pkgCache::PkgIterator const &/*pkg*/, std::string const &/*pattern*/) { } /*}}}*/ @@ -901,7 +901,7 @@ APT_IGNORE_DEPRECATED_POP break; } } -APT_PURE void CacheSetHelper::showSelectedVersion(pkgCache::PkgIterator const &/*Pkg*/, +void CacheSetHelper::showSelectedVersion(pkgCache::PkgIterator const &/*Pkg*/, pkgCache::VerIterator const /*Ver*/, std::string const &/*ver*/, bool const /*verIsRel*/) { diff --git a/apt-pkg/clean.cc b/apt-pkg/clean.cc index 23d062d8a..04a7c4910 100644 --- a/apt-pkg/clean.cc +++ b/apt-pkg/clean.cc @@ -148,4 +148,4 @@ bool pkgArchiveCleaner::Go(std::string Dir,pkgCache &Cache) /*}}}*/ pkgArchiveCleaner::pkgArchiveCleaner() : d(NULL) {} -APT_PURE pkgArchiveCleaner::~pkgArchiveCleaner() {} +pkgArchiveCleaner::~pkgArchiveCleaner() {} diff --git a/apt-pkg/indexcopy.cc b/apt-pkg/indexcopy.cc index cb23a860f..872adcaa8 100644 --- a/apt-pkg/indexcopy.cc +++ b/apt-pkg/indexcopy.cc @@ -785,13 +785,13 @@ bool TranslationsCopy::CopyTranslations(string CDROM,string Name, /*{{{*/ /*}}}*/ IndexCopy::IndexCopy() : d(nullptr), Section(nullptr) {} -APT_PURE IndexCopy::~IndexCopy() {} +IndexCopy::~IndexCopy() {} PackageCopy::PackageCopy() : IndexCopy(), d(NULL) {} -APT_PURE PackageCopy::~PackageCopy() {} +PackageCopy::~PackageCopy() {} SourceCopy::SourceCopy() : IndexCopy(), d(NULL) {} -APT_PURE SourceCopy::~SourceCopy() {} +SourceCopy::~SourceCopy() {} TranslationsCopy::TranslationsCopy() : d(nullptr), Section(nullptr) {} -APT_PURE TranslationsCopy::~TranslationsCopy() {} +TranslationsCopy::~TranslationsCopy() {} SigVerify::SigVerify() : d(NULL) {} -APT_PURE SigVerify::~SigVerify() {} +SigVerify::~SigVerify() {} diff --git a/apt-pkg/indexfile.cc b/apt-pkg/indexfile.cc index 0e205a562..679e2eab8 100644 --- a/apt-pkg/indexfile.cc +++ b/apt-pkg/indexfile.cc @@ -407,6 +407,6 @@ pkgCache::PkgFileIterator pkgDebianIndexFile::FindInCache(pkgCache &Cache) const return File; } -APT_PURE pkgIndexFile::~pkgIndexFile() {} -APT_PURE pkgDebianIndexTargetFile::~pkgDebianIndexTargetFile() {} -APT_PURE pkgDebianIndexRealFile::~pkgDebianIndexRealFile() {} +pkgIndexFile::~pkgIndexFile() {} +pkgDebianIndexTargetFile::~pkgDebianIndexTargetFile() {} +pkgDebianIndexRealFile::~pkgDebianIndexRealFile() {} diff --git a/apt-pkg/install-progress.cc b/apt-pkg/install-progress.cc index 09bf465bf..f9c8b6d96 100644 --- a/apt-pkg/install-progress.cc +++ b/apt-pkg/install-progress.cc @@ -103,7 +103,7 @@ void PackageManagerProgressFd::StartDpkg() WriteToStatusFd(GetProgressFdString("pmstatus", "dpkg-exec", StepsDone, StepsTotal, _("Running dpkg"))); } -APT_PURE void PackageManagerProgressFd::Stop() +void PackageManagerProgressFd::Stop() { } @@ -184,7 +184,7 @@ void PackageManagerProgressDeb822Fd::StartDpkg() WriteToStatusFd(GetProgressDeb822String("progress", nullptr, StepsDone, StepsTotal, _("Running dpkg"))); } -APT_PURE void PackageManagerProgressDeb822Fd::Stop() +void PackageManagerProgressDeb822Fd::Stop() { } -- cgit v1.2.3