From c8a4ce6cbed57ae108dc955d4a850f9b129a0693 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Tue, 16 Jun 2015 16:22:46 +0200 Subject: add d-pointer, virtual destructors and de-inline de/constructors To have a chance to keep the ABI for a while we need all three to team up. One of them missing and we might loose, so ensuring that they are available is a very tedious but needed task once in a while. Git-Dch: Ignore --- apt-pkg/pkgcachegen.h | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) (limited to 'apt-pkg/pkgcachegen.h') diff --git a/apt-pkg/pkgcachegen.h b/apt-pkg/pkgcachegen.h index ade93795b..3c1a40972 100644 --- a/apt-pkg/pkgcachegen.h +++ b/apt-pkg/pkgcachegen.h @@ -1,6 +1,5 @@ // -*- mode: cpp; mode: fold -*- // Description /*{{{*/ -// $Id: pkgcachegen.h,v 1.19 2002/07/08 03:13:30 jgg Exp $ /* ###################################################################### Package Cache Generator - Generator for the cache structure. @@ -123,9 +122,10 @@ class APT_HIDDEN pkgCacheGenerator /*{{{*/ void ReMap(void const * const oldMap, void const * const newMap); pkgCacheGenerator(DynamicMMap *Map,OpProgress *Progress); - ~pkgCacheGenerator(); + virtual ~pkgCacheGenerator(); private: + void *d; APT_HIDDEN bool MergeListGroup(ListParser &List, std::string const &GrpName); APT_HIDDEN bool MergeListPackage(ListParser &List, pkgCache::PkgIterator &Pkg); APT_HIDDEN bool MergeListVersion(ListParser &List, pkgCache::PkgIterator &Pkg, @@ -151,7 +151,9 @@ class APT_HIDDEN pkgCacheGenerator::ListParser // Flag file dependencies bool FoundFileDeps; - + + void *d; + protected: inline map_stringitem_t StoreString(pkgCacheGenerator::StringType const type, std::string const &S) {return Owner->StoreString(type, S);}; @@ -182,10 +184,7 @@ class APT_HIDDEN pkgCacheGenerator::ListParser * \param Hash of the currently parsed version * \param Ver to compare with */ -#if APT_PKG_ABI >= 413 - virtual -#endif - APT_PURE bool SameVersion(unsigned short const Hash, pkgCache::VerIterator const &Ver); + virtual bool SameVersion(unsigned short const Hash, pkgCache::VerIterator const &Ver); virtual bool UsePackage(pkgCache::PkgIterator &Pkg, pkgCache::VerIterator &Ver) = 0; virtual map_filesize_t Offset() = 0; @@ -197,8 +196,8 @@ class APT_HIDDEN pkgCacheGenerator::ListParser virtual bool CollectFileProvides(pkgCache &/*Cache*/, pkgCache::VerIterator &/*Ver*/) {return true;}; - ListParser() : Owner(NULL), OldDepLast(NULL), FoundFileDeps(false) {}; - virtual ~ListParser() {}; + ListParser(); + virtual ~ListParser(); }; /*}}}*/ -- cgit v1.2.3