summaryrefslogtreecommitdiff
path: root/apt-pkg
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@debian.org>2017-08-24 16:55:15 +0200
committerJulian Andres Klode <jak@debian.org>2017-08-24 16:56:52 +0200
commit0e4ac8334d02ea256f750ad61689f28ff1ebdf6c (patch)
treed1a1b22ec1039c8f8cd2450b28351c34b13605b3 /apt-pkg
parent03590fb98226bfdf3147eb78effc3fa7987709bb (diff)
Replace APT_CONST with APT_PURE everywhere
As a follow up to the last commit, let's replace APT_CONST with APT_PURE everywhere to clean stuff up.
Diffstat (limited to 'apt-pkg')
-rw-r--r--apt-pkg/acquire-item.cc18
-rw-r--r--apt-pkg/acquire.cc6
-rw-r--r--apt-pkg/cachefilter.cc16
-rw-r--r--apt-pkg/cacheset.cc10
-rw-r--r--apt-pkg/clean.cc2
-rw-r--r--apt-pkg/contrib/cmndline.h2
-rw-r--r--apt-pkg/contrib/crc-16.h2
-rw-r--r--apt-pkg/contrib/hashes.h4
-rw-r--r--apt-pkg/contrib/strutl.cc4
-rw-r--r--apt-pkg/contrib/strutl.h8
-rw-r--r--apt-pkg/deb/debindexfile.h16
-rw-r--r--apt-pkg/depcache.cc6
-rw-r--r--apt-pkg/edsp/edspindexfile.h4
-rw-r--r--apt-pkg/edsp/edsplistparser.cc2
-rw-r--r--apt-pkg/edsp/edspsystem.h8
-rw-r--r--apt-pkg/indexcopy.cc10
-rw-r--r--apt-pkg/indexfile.cc6
-rw-r--r--apt-pkg/install-progress.cc4
-rw-r--r--apt-pkg/pkgcache.h4
19 files changed, 66 insertions, 66 deletions
diff --git a/apt-pkg/acquire-item.cc b/apt-pkg/acquire-item.cc
index 4e47b9c30..bc9998c02 100644
--- a/apt-pkg/acquire-item.cc
+++ b/apt-pkg/acquire-item.cc
@@ -280,7 +280,7 @@ static HashStringList GetExpectedHashesFromFor(metaIndex * const Parser, std::st
to true and should be as restrictive as possible for false cases. Note that if
a hash is returned by ::GetExpectedHashes it must match. Only if it doesn't
::HashesRequired is called to evaluate if its okay to have no hashes. */
-APT_CONST bool pkgAcqTransactionItem::HashesRequired() const
+APT_PURE bool pkgAcqTransactionItem::HashesRequired() const
{
/* signed repositories obviously have a parser and good hashes.
unsigned repositories, too, as even if we can't trust them for security,
@@ -307,7 +307,7 @@ HashStringList pkgAcqTransactionItem::GetExpectedHashes() const
return GetExpectedHashesFor(GetMetaKey());
}
-APT_CONST bool pkgAcqMetaBase::HashesRequired() const
+APT_PURE bool pkgAcqMetaBase::HashesRequired() const
{
// Release and co have no hashes 'by design'.
return false;
@@ -317,7 +317,7 @@ HashStringList pkgAcqMetaBase::GetExpectedHashes() const
return HashStringList();
}
-APT_CONST bool pkgAcqIndexDiffs::HashesRequired() const
+APT_PURE bool pkgAcqIndexDiffs::HashesRequired() const
{
/* We can't check hashes of rred result as we don't know what the
hash of the file will be. We just know the hash of the patch(es),
@@ -334,7 +334,7 @@ HashStringList pkgAcqIndexDiffs::GetExpectedHashes() const
return HashStringList();
}
-APT_CONST bool pkgAcqIndexMergeDiffs::HashesRequired() const
+APT_PURE bool pkgAcqIndexMergeDiffs::HashesRequired() const
{
/* @see #pkgAcqIndexDiffs::HashesRequired, with the difference that
we can check the rred result after all patches are applied as
@@ -352,7 +352,7 @@ HashStringList pkgAcqIndexMergeDiffs::GetExpectedHashes() const
return HashStringList();
}
-APT_CONST bool pkgAcqArchive::HashesRequired() const
+APT_PURE bool pkgAcqArchive::HashesRequired() const
{
return LocalSource == false;
}
@@ -362,7 +362,7 @@ HashStringList pkgAcqArchive::GetExpectedHashes() const
return ExpectedHashes;
}
-APT_CONST bool pkgAcqFile::HashesRequired() const
+APT_PURE bool pkgAcqFile::HashesRequired() const
{
// supplied as parameter at creation time, so the caller decides
return ExpectedHashes.usable();
@@ -712,7 +712,7 @@ std::string pkgAcquire::Item::ShortDesc() const /*{{{*/
return DescURI();
}
/*}}}*/
-APT_CONST void pkgAcquire::Item::Finished() /*{{{*/
+APT_PURE void pkgAcquire::Item::Finished() /*{{{*/
{
}
/*}}}*/
@@ -721,12 +721,12 @@ APT_PURE pkgAcquire * pkgAcquire::Item::GetOwner() const /*{{{*/
return Owner;
}
/*}}}*/
-APT_CONST pkgAcquire::ItemDesc &pkgAcquire::Item::GetItemDesc() /*{{{*/
+APT_PURE pkgAcquire::ItemDesc &pkgAcquire::Item::GetItemDesc() /*{{{*/
{
return Desc;
}
/*}}}*/
-APT_CONST bool pkgAcquire::Item::IsTrusted() const /*{{{*/
+APT_PURE bool pkgAcquire::Item::IsTrusted() const /*{{{*/
{
return false;
}
diff --git a/apt-pkg/acquire.cc b/apt-pkg/acquire.cc
index c26e4e07c..408cf6df5 100644
--- a/apt-pkg/acquire.cc
+++ b/apt-pkg/acquire.cc
@@ -1430,6 +1430,6 @@ pkgAcquire::UriIterator::UriIterator(pkgAcquire::Queue *Q) : d(NULL), CurQ(Q), C
}
}
-APT_CONST pkgAcquire::UriIterator::~UriIterator() {}
-APT_CONST pkgAcquire::MethodConfig::~MethodConfig() {}
-APT_CONST pkgAcquireStatus::~pkgAcquireStatus() {}
+APT_PURE pkgAcquire::UriIterator::~UriIterator() {}
+APT_PURE pkgAcquire::MethodConfig::~MethodConfig() {}
+APT_PURE pkgAcquireStatus::~pkgAcquireStatus() {}
diff --git a/apt-pkg/cachefilter.cc b/apt-pkg/cachefilter.cc
index 4cbe162e9..c49f5dfd0 100644
--- a/apt-pkg/cachefilter.cc
+++ b/apt-pkg/cachefilter.cc
@@ -27,8 +27,8 @@ namespace APT {
APT_HIDDEN std::unordered_map<std::string, std::vector<std::string>> ArchToTupleMap;
namespace CacheFilter {
-APT_CONST Matcher::~Matcher() {}
-APT_CONST PackageMatcher::~PackageMatcher() {}
+APT_PURE Matcher::~Matcher() {}
+APT_PURE PackageMatcher::~PackageMatcher() {}
// Name matches RegEx /*{{{*/
PackageNameMatchesRegEx::PackageNameMatchesRegEx(std::string const &Pattern) {
@@ -165,13 +165,13 @@ APT_PURE bool PackageIsNewInstall::operator() (pkgCache::PkgIterator const &Pkg)
PackageIsNewInstall::~PackageIsNewInstall() {}
/*}}}*/
// Generica like True, False, NOT, AND, OR /*{{{*/
-APT_CONST bool TrueMatcher::operator() (pkgCache::PkgIterator const &) { return true; }
-APT_CONST bool TrueMatcher::operator() (pkgCache::GrpIterator const &) { return true; }
-APT_CONST bool TrueMatcher::operator() (pkgCache::VerIterator const &) { return true; }
+APT_PURE bool TrueMatcher::operator() (pkgCache::PkgIterator const &) { return true; }
+APT_PURE bool TrueMatcher::operator() (pkgCache::GrpIterator const &) { return true; }
+APT_PURE bool TrueMatcher::operator() (pkgCache::VerIterator const &) { return true; }
-APT_CONST bool FalseMatcher::operator() (pkgCache::PkgIterator const &) { return false; }
-APT_CONST bool FalseMatcher::operator() (pkgCache::GrpIterator const &) { return false; }
-APT_CONST bool FalseMatcher::operator() (pkgCache::VerIterator const &) { return false; }
+APT_PURE bool FalseMatcher::operator() (pkgCache::PkgIterator const &) { return false; }
+APT_PURE bool FalseMatcher::operator() (pkgCache::GrpIterator const &) { return false; }
+APT_PURE bool FalseMatcher::operator() (pkgCache::VerIterator const &) { return false; }
NOTMatcher::NOTMatcher(Matcher * const matcher) : matcher(matcher) {}
bool NOTMatcher::operator() (pkgCache::PkgIterator const &Pkg) { return ! (*matcher)(Pkg); }
diff --git a/apt-pkg/cacheset.cc b/apt-pkg/cacheset.cc
index 92f707cba..a6570c95b 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_CONST void CacheSetHelper::canNotFindPackage(PackageContainerInterface * const /*pci*/, pkgCacheFile &/*Cache*/, std::string const &/*str*/) {
+APT_PURE void CacheSetHelper::canNotFindPackage(PackageContainerInterface * const /*pci*/, pkgCacheFile &/*Cache*/, std::string const &/*str*/) {
}
/*}}}*/
/*}}}*/
@@ -863,17 +863,17 @@ APT_IGNORE_DEPRECATED_POP
}
}
// showTaskSelection /*{{{*/
-APT_CONST void CacheSetHelper::showTaskSelection(pkgCache::PkgIterator const &/*pkg*/,
+APT_PURE void CacheSetHelper::showTaskSelection(pkgCache::PkgIterator const &/*pkg*/,
std::string const &/*pattern*/) {
}
/*}}}*/
// showRegExSelection /*{{{*/
-APT_CONST void CacheSetHelper::showRegExSelection(pkgCache::PkgIterator const &/*pkg*/,
+APT_PURE void CacheSetHelper::showRegExSelection(pkgCache::PkgIterator const &/*pkg*/,
std::string const &/*pattern*/) {
}
/*}}}*/
// showFnmatchSelection /*{{{*/
-APT_CONST void CacheSetHelper::showFnmatchSelection(pkgCache::PkgIterator const &/*pkg*/,
+APT_PURE void CacheSetHelper::showFnmatchSelection(pkgCache::PkgIterator const &/*pkg*/,
std::string const &/*pattern*/) {
}
/*}}}*/
@@ -901,7 +901,7 @@ APT_IGNORE_DEPRECATED_POP
break;
}
}
-APT_CONST void CacheSetHelper::showSelectedVersion(pkgCache::PkgIterator const &/*Pkg*/,
+APT_PURE 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 e9bf73b6c..23d062d8a 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_CONST pkgArchiveCleaner::~pkgArchiveCleaner() {}
+APT_PURE pkgArchiveCleaner::~pkgArchiveCleaner() {}
diff --git a/apt-pkg/contrib/cmndline.h b/apt-pkg/contrib/cmndline.h
index 805cb9eae..2751fb1db 100644
--- a/apt-pkg/contrib/cmndline.h
+++ b/apt-pkg/contrib/cmndline.h
@@ -92,7 +92,7 @@ class CommandLine
unsigned int const argc, char const * const * const argv) APT_PURE;
static CommandLine::Args MakeArgs(char ShortOpt, char const *LongOpt,
- char const *ConfName, unsigned long Flags) APT_CONST;
+ char const *ConfName, unsigned long Flags) APT_PURE;
CommandLine();
CommandLine(Args *AList,Configuration *Conf);
diff --git a/apt-pkg/contrib/crc-16.h b/apt-pkg/contrib/crc-16.h
index 6cc3556c6..228b00bc3 100644
--- a/apt-pkg/contrib/crc-16.h
+++ b/apt-pkg/contrib/crc-16.h
@@ -13,7 +13,7 @@
#include <apt-pkg/macros.h>
#define INIT_FCS 0xffff
-unsigned short AddCRC16Byte(unsigned short fcs, unsigned char byte) APT_CONST;
+unsigned short AddCRC16Byte(unsigned short fcs, unsigned char byte) APT_PURE;
unsigned short AddCRC16(unsigned short fcs, void const *buf,
unsigned long long len) APT_PURE;
diff --git a/apt-pkg/contrib/hashes.h b/apt-pkg/contrib/hashes.h
index 1f8f45cb1..11521008a 100644
--- a/apt-pkg/contrib/hashes.h
+++ b/apt-pkg/contrib/hashes.h
@@ -72,7 +72,7 @@ class HashString
bool operator!=(HashString const &other) const;
// return the list of hashes we support
- static APT_CONST const char** SupportedHashes();
+ static APT_PURE const char** SupportedHashes();
};
class HashStringList
@@ -225,7 +225,7 @@ APT_IGNORE_DEPRECATED_PUSH
APT_IGNORE_DEPRECATED_POP
private:
- APT_HIDDEN APT_CONST inline unsigned int boolsToFlag(bool const addMD5, bool const addSHA1, bool const addSHA256, bool const addSHA512)
+ APT_HIDDEN APT_PURE inline unsigned int boolsToFlag(bool const addMD5, bool const addSHA1, bool const addSHA256, bool const addSHA512)
{
unsigned int Hashes = ~0;
if (addMD5 == false) Hashes &= ~MD5SUM;
diff --git a/apt-pkg/contrib/strutl.cc b/apt-pkg/contrib/strutl.cc
index 964f0d6c6..f2fc0b6a6 100644
--- a/apt-pkg/contrib/strutl.cc
+++ b/apt-pkg/contrib/strutl.cc
@@ -1482,7 +1482,7 @@ string StripEpoch(const string &VerStr)
standard tolower/toupper and as a bonus avoids problems with different
locales - we only operate on ascii chars anyway. */
#undef tolower_ascii
-int tolower_ascii(int const c) APT_CONST APT_COLD;
+int tolower_ascii(int const c) APT_PURE APT_COLD;
int tolower_ascii(int const c)
{
return tolower_ascii_inline(c);
@@ -1496,7 +1496,7 @@ int tolower_ascii(int const c)
standard isspace() and as a bonus avoids problems with different
locales - we only operate on ascii chars anyway. */
#undef isspace_ascii
-int isspace_ascii(int const c) APT_CONST APT_COLD;
+int isspace_ascii(int const c) APT_PURE APT_COLD;
int isspace_ascii(int const c)
{
return isspace_ascii_inline(c);
diff --git a/apt-pkg/contrib/strutl.h b/apt-pkg/contrib/strutl.h
index cc39521da..f76fbd4ab 100644
--- a/apt-pkg/contrib/strutl.h
+++ b/apt-pkg/contrib/strutl.h
@@ -130,7 +130,7 @@ std::vector<std::string> VectorizeString(std::string const &haystack, char const
*/
std::vector<std::string> StringSplit(std::string const &input,
std::string const &sep,
- unsigned int maxsplit=std::numeric_limits<unsigned int>::max()) APT_CONST;
+ unsigned int maxsplit=std::numeric_limits<unsigned int>::max()) APT_PURE;
void ioprintf(std::ostream &out,const char *format,...) APT_PRINTF(2);
void strprintf(std::string &out,const char *format,...) APT_PRINTF(2);
@@ -141,17 +141,17 @@ bool CheckDomainList(const std::string &Host, const std::string &List);
#define tolower_ascii tolower_ascii_inline
#define isspace_ascii isspace_ascii_inline
-APT_CONST APT_HOT
+APT_PURE APT_HOT
static inline int tolower_ascii_unsafe(int const c)
{
return c | 0x20;
}
-APT_CONST APT_HOT
+APT_PURE APT_HOT
static inline int tolower_ascii_inline(int const c)
{
return (c >= 'A' && c <= 'Z') ? c + 32 : c;
}
-APT_CONST APT_HOT
+APT_PURE APT_HOT
static inline int isspace_ascii_inline(int const c)
{
// 9='\t',10='\n',11='\v',12='\f',13='\r',32=' '
diff --git a/apt-pkg/deb/debindexfile.h b/apt-pkg/deb/debindexfile.h
index 40a9e4bbc..5c89f9c54 100644
--- a/apt-pkg/deb/debindexfile.h
+++ b/apt-pkg/deb/debindexfile.h
@@ -35,7 +35,7 @@ protected:
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
// Interface for the Cache Generator
virtual bool HasPackages() const APT_OVERRIDE {return true;};
@@ -55,7 +55,7 @@ protected:
virtual uint8_t GetIndexFlags() const APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
// Stuff for accessing files on remote items
virtual std::string ArchiveInfo(pkgCache::VerIterator const &Ver) const APT_OVERRIDE;
@@ -78,7 +78,7 @@ protected:
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
// Interface for the Cache Generator
virtual bool HasPackages() const APT_OVERRIDE;
@@ -96,7 +96,7 @@ class debSourcesIndex : public pkgDebianIndexTargetFile
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
// Stuff for accessing files on remote items
virtual std::string SourceInfo(pkgSrcRecords::Parser const &Record,
@@ -125,7 +125,7 @@ protected:
APT_HIDDEN virtual pkgCacheListParser * CreateListParser(FileFd &Pkg) APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
/** get the control (file) content of the deb file
*
@@ -158,7 +158,7 @@ protected:
virtual uint8_t GetIndexFlags() const APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
virtual pkgSrcRecords::Parser *CreateSrcParser() const APT_OVERRIDE;
virtual bool HasPackages() const APT_OVERRIDE {return false;};
@@ -172,7 +172,7 @@ protected:
virtual std::string GetComponent() const APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
};
class debStringPackageIndex : public pkgDebianIndexRealFile
@@ -184,7 +184,7 @@ protected:
virtual uint8_t GetIndexFlags() const APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
// Interface for the Cache Generator
virtual bool HasPackages() const APT_OVERRIDE {return true;};
diff --git a/apt-pkg/depcache.cc b/apt-pkg/depcache.cc
index 27467441c..c66ab2ded 100644
--- a/apt-pkg/depcache.cc
+++ b/apt-pkg/depcache.cc
@@ -1795,11 +1795,11 @@ bool pkgDepCache::Policy::IsImportantDep(DepIterator const &Dep) const
}
/*}}}*/
// Policy::GetPriority - Get the priority of the package pin /*{{{*/
-APT_CONST signed short pkgDepCache::Policy::GetPriority(pkgCache::PkgIterator const &/*Pkg*/)
+APT_PURE signed short pkgDepCache::Policy::GetPriority(pkgCache::PkgIterator const &/*Pkg*/)
{ return 0; }
-APT_CONST signed short pkgDepCache::Policy::GetPriority(pkgCache::VerIterator const &/*Ver*/, bool /*ConsiderFiles*/)
+APT_PURE signed short pkgDepCache::Policy::GetPriority(pkgCache::VerIterator const &/*Ver*/, bool /*ConsiderFiles*/)
{ return 0; }
-APT_CONST signed short pkgDepCache::Policy::GetPriority(pkgCache::PkgFileIterator const &/*File*/)
+APT_PURE signed short pkgDepCache::Policy::GetPriority(pkgCache::PkgFileIterator const &/*File*/)
{ return 0; }
/*}}}*/
pkgDepCache::InRootSetFunc *pkgDepCache::GetRootSetFunc() /*{{{*/
diff --git a/apt-pkg/edsp/edspindexfile.h b/apt-pkg/edsp/edspindexfile.h
index e146ca80c..4ac0f9d72 100644
--- a/apt-pkg/edsp/edspindexfile.h
+++ b/apt-pkg/edsp/edspindexfile.h
@@ -40,7 +40,7 @@ protected:
virtual std::string GetComponent() const APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
edspIndex(std::string const &File);
virtual ~edspIndex();
@@ -53,7 +53,7 @@ protected:
virtual std::string GetComponent() const APT_OVERRIDE;
public:
- virtual const Type *GetType() const APT_OVERRIDE APT_CONST;
+ virtual const Type *GetType() const APT_OVERRIDE APT_PURE;
eippIndex(std::string const &File);
virtual ~eippIndex();
diff --git a/apt-pkg/edsp/edsplistparser.cc b/apt-pkg/edsp/edsplistparser.cc
index b118e127d..bd02a128a 100644
--- a/apt-pkg/edsp/edsplistparser.cc
+++ b/apt-pkg/edsp/edsplistparser.cc
@@ -69,7 +69,7 @@ unsigned short edspLikeListParser::VersionHash()
}
/*}}}*/
// ListParser::LoadReleaseInfo - Load the release information /*{{{*/
-APT_CONST bool edspLikeListParser::LoadReleaseInfo(pkgCache::RlsFileIterator & /*FileI*/,
+APT_PURE bool edspLikeListParser::LoadReleaseInfo(pkgCache::RlsFileIterator & /*FileI*/,
FileFd & /*File*/, std::string const &/*component*/)
{
return true;
diff --git a/apt-pkg/edsp/edspsystem.h b/apt-pkg/edsp/edspsystem.h
index af8bcf128..c70d8107a 100644
--- a/apt-pkg/edsp/edspsystem.h
+++ b/apt-pkg/edsp/edspsystem.h
@@ -29,11 +29,11 @@ protected:
std::unique_ptr<pkgIndexFile> StatusFile;
public:
- virtual bool Lock() APT_OVERRIDE APT_CONST;
- virtual bool UnLock(bool NoErrors = false) APT_OVERRIDE APT_CONST;
- virtual pkgPackageManager *CreatePM(pkgDepCache *Cache) const APT_OVERRIDE APT_CONST;
+ virtual bool Lock() APT_OVERRIDE APT_PURE;
+ virtual bool UnLock(bool NoErrors = false) APT_OVERRIDE APT_PURE;
+ virtual pkgPackageManager *CreatePM(pkgDepCache *Cache) const APT_OVERRIDE APT_PURE;
virtual bool Initialize(Configuration &Cnf) APT_OVERRIDE;
- virtual bool ArchiveSupported(const char *Type) APT_OVERRIDE APT_CONST;
+ virtual bool ArchiveSupported(const char *Type) APT_OVERRIDE APT_PURE;
virtual signed Score(Configuration const &Cnf) APT_OVERRIDE;
virtual bool FindIndex(pkgCache::PkgFileIterator File,
pkgIndexFile *&Found) const APT_OVERRIDE;
diff --git a/apt-pkg/indexcopy.cc b/apt-pkg/indexcopy.cc
index 11d2e934e..968734118 100644
--- a/apt-pkg/indexcopy.cc
+++ b/apt-pkg/indexcopy.cc
@@ -772,13 +772,13 @@ bool TranslationsCopy::CopyTranslations(string CDROM,string Name, /*{{{*/
/*}}}*/
IndexCopy::IndexCopy() : d(nullptr), Section(nullptr) {}
-APT_CONST IndexCopy::~IndexCopy() {}
+APT_PURE IndexCopy::~IndexCopy() {}
PackageCopy::PackageCopy() : IndexCopy(), d(NULL) {}
-APT_CONST PackageCopy::~PackageCopy() {}
+APT_PURE PackageCopy::~PackageCopy() {}
SourceCopy::SourceCopy() : IndexCopy(), d(NULL) {}
-APT_CONST SourceCopy::~SourceCopy() {}
+APT_PURE SourceCopy::~SourceCopy() {}
TranslationsCopy::TranslationsCopy() : d(nullptr), Section(nullptr) {}
-APT_CONST TranslationsCopy::~TranslationsCopy() {}
+APT_PURE TranslationsCopy::~TranslationsCopy() {}
SigVerify::SigVerify() : d(NULL) {}
-APT_CONST SigVerify::~SigVerify() {}
+APT_PURE SigVerify::~SigVerify() {}
diff --git a/apt-pkg/indexfile.cc b/apt-pkg/indexfile.cc
index 492f29c5a..3ac5b3679 100644
--- a/apt-pkg/indexfile.cc
+++ b/apt-pkg/indexfile.cc
@@ -403,6 +403,6 @@ pkgCache::PkgFileIterator pkgDebianIndexFile::FindInCache(pkgCache &Cache) const
return File;
}
-APT_CONST pkgIndexFile::~pkgIndexFile() {}
-APT_CONST pkgDebianIndexTargetFile::~pkgDebianIndexTargetFile() {}
-APT_CONST pkgDebianIndexRealFile::~pkgDebianIndexRealFile() {}
+APT_PURE pkgIndexFile::~pkgIndexFile() {}
+APT_PURE pkgDebianIndexTargetFile::~pkgDebianIndexTargetFile() {}
+APT_PURE pkgDebianIndexRealFile::~pkgDebianIndexRealFile() {}
diff --git a/apt-pkg/install-progress.cc b/apt-pkg/install-progress.cc
index 913068a66..2c2205d2b 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_CONST void PackageManagerProgressFd::Stop()
+APT_PURE void PackageManagerProgressFd::Stop()
{
}
@@ -184,7 +184,7 @@ void PackageManagerProgressDeb822Fd::StartDpkg()
WriteToStatusFd(GetProgressDeb822String("progress", nullptr, StepsDone, StepsTotal, _("Running dpkg")));
}
-APT_CONST void PackageManagerProgressDeb822Fd::Stop()
+APT_PURE void PackageManagerProgressDeb822Fd::Stop()
{
}
diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h
index e1597c1b1..5c33c7073 100644
--- a/apt-pkg/pkgcache.h
+++ b/apt-pkg/pkgcache.h
@@ -276,8 +276,8 @@ class pkgCache /*{{{*/
pkgVersioningSystem *VS;
// Converters
- static const char *CompTypeDeb(unsigned char Comp) APT_CONST;
- static const char *CompType(unsigned char Comp) APT_CONST;
+ static const char *CompTypeDeb(unsigned char Comp) APT_PURE;
+ static const char *CompType(unsigned char Comp) APT_PURE;
static const char *DepType(unsigned char Dep);
pkgCache(MMap *Map,bool DoMap = true);