From 255c9e4b74fe677d723c51d3450869ad45ca5463 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Tue, 25 Feb 2014 22:10:40 +0100 Subject: make doxygen more quiet, fix issues and disable latex Git-Dch: Ignore --- apt-pkg/pkgcache.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'apt-pkg/pkgcache.h') diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h index c31c5f30b..669904c84 100644 --- a/apt-pkg/pkgcache.h +++ b/apt-pkg/pkgcache.h @@ -451,7 +451,7 @@ struct pkgCache::PackageFile /** \brief Modification time for the file */ time_t mtime; - /* @TODO document PackageFile::Flags */ + /** @TODO document PackageFile::Flags */ unsigned long Flags; // Linked list @@ -474,7 +474,7 @@ struct pkgCache::VerFile map_ptrloc NextFile; // PkgVerFile /** \brief position in the package file */ map_ptrloc Offset; // File offset - /* @TODO document pkgCache::VerFile::Size */ + /** @TODO document pkgCache::VerFile::Size */ unsigned long Size; }; /*}}}*/ @@ -488,7 +488,7 @@ struct pkgCache::DescFile map_ptrloc NextFile; // PkgVerFile /** \brief position in the file */ map_ptrloc Offset; // File offset - /* @TODO document pkgCache::DescFile::Size */ + /** @TODO document pkgCache::DescFile::Size */ unsigned long Size; }; /*}}}*/ @@ -571,7 +571,7 @@ struct pkgCache::Description and to check that the Translation is up-to-date. */ map_ptrloc md5sum; // StringItem - /* @TODO document pkgCache::Description::FileList */ + /** @TODO document pkgCache::Description::FileList */ map_ptrloc FileList; // DescFile /** \brief next translation for this description */ map_ptrloc NextDesc; // Description -- cgit v1.2.3 From d3e8fbb395f57954acd7a2095f02ce530a05ec6a Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 27 Feb 2014 01:20:53 +0100 Subject: =?UTF-8?q?warning:=20extra=20=E2=80=98;=E2=80=99=20[-Wpedantic]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Git-Dch: Ignore Reported-By: gcc -Wpedantic --- apt-pkg/pkgcache.h | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'apt-pkg/pkgcache.h') diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h index 669904c84..9a88246a1 100644 --- a/apt-pkg/pkgcache.h +++ b/apt-pkg/pkgcache.h @@ -176,13 +176,13 @@ class pkgCache /*{{{*/ char *StrP; virtual bool ReMap(bool const &Errorchecks = true); - inline bool Sync() {return Map.Sync();}; - inline MMap &GetMap() {return Map;}; - inline void *DataEnd() {return ((unsigned char *)Map.Data()) + Map.Size();}; + inline bool Sync() {return Map.Sync();} + inline MMap &GetMap() {return Map;} + inline void *DataEnd() {return ((unsigned char *)Map.Data()) + Map.Size();} // String hashing function (512 range) - inline unsigned long Hash(const std::string &S) const {return sHash(S);}; - inline unsigned long Hash(const char *S) const {return sHash(S);}; + inline unsigned long Hash(const std::string &S) const {return sHash(S);} + inline unsigned long Hash(const char *S) const {return sHash(S);} // Useful transformation things const char *Priority(unsigned char Priority); @@ -192,7 +192,7 @@ class pkgCache /*{{{*/ PkgIterator FindPkg(const std::string &Name); PkgIterator FindPkg(const std::string &Name, const std::string &Arch); - Header &Head() {return *HeaderP;}; + Header &Head() {return *HeaderP;} inline GrpIterator GrpBegin(); inline GrpIterator GrpEnd(); inline PkgIterator PkgBegin(); @@ -200,7 +200,7 @@ class pkgCache /*{{{*/ inline PkgFileIterator FileBegin(); inline PkgFileIterator FileEnd(); - inline bool MultiArchCache() const { return MultiArchEnabled; }; + inline bool MultiArchCache() const { return MultiArchEnabled; } inline char const * const NativeArch() const; // Make me a function @@ -212,7 +212,7 @@ class pkgCache /*{{{*/ static const char *DepType(unsigned char Dep); pkgCache(MMap *Map,bool DoMap = true); - virtual ~pkgCache() {}; + virtual ~pkgCache() {} private: bool MultiArchEnabled; @@ -662,26 +662,26 @@ struct pkgCache::StringItem inline char const * const pkgCache::NativeArch() const - { return StrP + HeaderP->Architecture; }; + { return StrP + HeaderP->Architecture; } #include -inline pkgCache::GrpIterator pkgCache::GrpBegin() - {return GrpIterator(*this);}; -inline pkgCache::GrpIterator pkgCache::GrpEnd() - {return GrpIterator(*this,GrpP);}; -inline pkgCache::PkgIterator pkgCache::PkgBegin() - {return PkgIterator(*this);}; -inline pkgCache::PkgIterator pkgCache::PkgEnd() - {return PkgIterator(*this,PkgP);}; +inline pkgCache::GrpIterator pkgCache::GrpBegin() + {return GrpIterator(*this);} +inline pkgCache::GrpIterator pkgCache::GrpEnd() + {return GrpIterator(*this,GrpP);} +inline pkgCache::PkgIterator pkgCache::PkgBegin() + {return PkgIterator(*this);} +inline pkgCache::PkgIterator pkgCache::PkgEnd() + {return PkgIterator(*this,PkgP);} inline pkgCache::PkgFileIterator pkgCache::FileBegin() - {return PkgFileIterator(*this,PkgFileP + HeaderP->FileList);}; + {return PkgFileIterator(*this,PkgFileP + HeaderP->FileList);} inline pkgCache::PkgFileIterator pkgCache::FileEnd() - {return PkgFileIterator(*this,PkgFileP);}; + {return PkgFileIterator(*this,PkgFileP);} // Oh I wish for Real Name Space Support class pkgCache::Namespace /*{{{*/ -{ +{ public: typedef pkgCache::GrpIterator GrpIterator; typedef pkgCache::PkgIterator PkgIterator; @@ -690,7 +690,7 @@ class pkgCache::Namespace /*{{{*/ typedef pkgCache::DepIterator DepIterator; typedef pkgCache::PrvIterator PrvIterator; typedef pkgCache::PkgFileIterator PkgFileIterator; - typedef pkgCache::VerFileIterator VerFileIterator; + typedef pkgCache::VerFileIterator VerFileIterator; typedef pkgCache::Version Version; typedef pkgCache::Description Description; typedef pkgCache::Package Package; -- cgit v1.2.3 From d64e130aa333837a8fda0f1bba51f2867ca520f7 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Sat, 1 Mar 2014 13:55:20 +0100 Subject: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] Reported-By: gcc -Wignored-qualifiers Git-Dch: Ignore --- apt-pkg/pkgcache.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apt-pkg/pkgcache.h') diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h index 9a88246a1..b3a714511 100644 --- a/apt-pkg/pkgcache.h +++ b/apt-pkg/pkgcache.h @@ -201,7 +201,7 @@ class pkgCache /*{{{*/ inline PkgFileIterator FileEnd(); inline bool MultiArchCache() const { return MultiArchEnabled; } - inline char const * const NativeArch() const; + inline char const * NativeArch(); // Make me a function pkgVersioningSystem *VS; @@ -661,7 +661,7 @@ struct pkgCache::StringItem /*}}}*/ -inline char const * const pkgCache::NativeArch() const +inline char const * pkgCache::NativeArch() { return StrP + HeaderP->Architecture; } #include -- 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/pkgcache.h | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'apt-pkg/pkgcache.h') diff --git a/apt-pkg/pkgcache.h b/apt-pkg/pkgcache.h index b3a714511..5e8a9630a 100644 --- a/apt-pkg/pkgcache.h +++ b/apt-pkg/pkgcache.h @@ -74,9 +74,11 @@ #ifndef PKGLIB_PKGCACHE_H #define PKGLIB_PKGCACHE_H +#include +#include + #include #include -#include #ifndef APT_8_CLEANER_HEADERS using std::string; @@ -156,8 +158,8 @@ class pkgCache /*{{{*/ std::string CacheFile; MMap ⤅ - unsigned long sHash(const std::string &S) const; - unsigned long sHash(const char *S) const; + unsigned long sHash(const std::string &S) const APT_PURE; + unsigned long sHash(const char *S) const APT_PURE; public: @@ -207,8 +209,8 @@ class pkgCache /*{{{*/ pkgVersioningSystem *VS; // Converters - static const char *CompTypeDeb(unsigned char Comp); - static const char *CompType(unsigned char Comp); + static const char *CompTypeDeb(unsigned char Comp) APT_CONST; + static const char *CompType(unsigned char Comp) APT_CONST; static const char *DepType(unsigned char Dep); pkgCache(MMap *Map,bool DoMap = true); @@ -318,7 +320,7 @@ struct pkgCache::Header /** \brief Size of the complete cache file */ unsigned long CacheFileSize; - bool CheckSizes(Header &Against) const; + bool CheckSizes(Header &Against) const APT_PURE; Header(); }; /*}}}*/ -- cgit v1.2.3