From 655122418d714f342b5d9789f45f8035f3fe8b9a Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Sat, 1 Mar 2014 15:11:42 +0100 Subject: =?UTF-8?q?warning:=20unused=20parameter=20=E2=80=98foo=E2=80=99?= =?UTF-8?q?=20[-Wunused-parameter]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reported-By: gcc -Wunused-parameter Git-Dch: Ignore --- apt-pkg/indexfile.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apt-pkg/indexfile.h') diff --git a/apt-pkg/indexfile.h b/apt-pkg/indexfile.h index a0096fa34..9a5c74200 100644 --- a/apt-pkg/indexfile.h +++ b/apt-pkg/indexfile.h @@ -78,10 +78,10 @@ class pkgIndexFile virtual bool Exists() const = 0; virtual bool HasPackages() const = 0; virtual unsigned long Size() const = 0; - virtual bool Merge(pkgCacheGenerator &Gen, OpProgress* Prog) const { return false; }; + virtual bool Merge(pkgCacheGenerator &/*Gen*/, OpProgress* /*Prog*/) const { return false; }; __deprecated virtual bool Merge(pkgCacheGenerator &Gen, OpProgress &Prog) const { return Merge(Gen, &Prog); }; - virtual bool MergeFileProvides(pkgCacheGenerator &Gen,OpProgress* Prog) const {return true;}; + virtual bool MergeFileProvides(pkgCacheGenerator &/*Gen*/,OpProgress* /*Prog*/) const {return true;}; __deprecated virtual bool MergeFileProvides(pkgCacheGenerator &Gen, OpProgress &Prog) const {return MergeFileProvides(Gen, &Prog);}; virtual pkgCache::PkgFileIterator FindInCache(pkgCache &Cache) const; -- cgit v1.2.3 From 453b82a388013e522b3a1b9fcd6ed0810dab1f4f Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Wed, 5 Mar 2014 22:11:25 +0100 Subject: cleanup headers and especially #includes everywhere Beside being a bit cleaner it hopefully also resolves oddball problems I have with high levels of parallel jobs. Git-Dch: Ignore Reported-By: iwyu (include-what-you-use) --- apt-pkg/indexfile.h | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'apt-pkg/indexfile.h') diff --git a/apt-pkg/indexfile.h b/apt-pkg/indexfile.h index 9a5c74200..98cdda603 100644 --- a/apt-pkg/indexfile.h +++ b/apt-pkg/indexfile.h @@ -22,18 +22,21 @@ #ifndef PKGLIB_INDEXFILE_H #define PKGLIB_INDEXFILE_H - -#include -#include #include #include +#include +#include #include +#include + #ifndef APT_8_CLEANER_HEADERS using std::string; #endif - +#ifndef APT_10_CLEANER_HEADERS class pkgAcquire; +#endif + class pkgCacheGenerator; class OpProgress; @@ -79,10 +82,10 @@ class pkgIndexFile virtual bool HasPackages() const = 0; virtual unsigned long Size() const = 0; virtual bool Merge(pkgCacheGenerator &/*Gen*/, OpProgress* /*Prog*/) const { return false; }; - __deprecated virtual bool Merge(pkgCacheGenerator &Gen, OpProgress &Prog) const + APT_DEPRECATED virtual bool Merge(pkgCacheGenerator &Gen, OpProgress &Prog) const { return Merge(Gen, &Prog); }; virtual bool MergeFileProvides(pkgCacheGenerator &/*Gen*/,OpProgress* /*Prog*/) const {return true;}; - __deprecated virtual bool MergeFileProvides(pkgCacheGenerator &Gen, OpProgress &Prog) const + APT_DEPRECATED virtual bool MergeFileProvides(pkgCacheGenerator &Gen, OpProgress &Prog) const {return MergeFileProvides(Gen, &Prog);}; virtual pkgCache::PkgFileIterator FindInCache(pkgCache &Cache) const; -- cgit v1.2.3 From a02db58fd50ef7fc2f0284852c6b3f98e458a232 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 6 Mar 2014 00:33:10 +0100 Subject: follow method attribute suggestions by gcc Git-Dch: Ignore Reported-By: gcc -Wsuggest-attribute={pure,const,noreturn} --- apt-pkg/indexfile.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'apt-pkg/indexfile.h') diff --git a/apt-pkg/indexfile.h b/apt-pkg/indexfile.h index 98cdda603..b5c9ac77e 100644 --- a/apt-pkg/indexfile.h +++ b/apt-pkg/indexfile.h @@ -54,7 +54,7 @@ class pkgIndexFile // Global list of Items supported static Type **GlobalList; static unsigned long GlobalListLen; - static Type *GetType(const char *Type); + static Type *GetType(const char *Type) APT_PURE; const char *Label; -- cgit v1.2.3