X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/5dd00edbcf702cac1ea22392796c65881a8ef6f9..1a3296c0bd67c46c6ff791345b6101edcb97e778:/apt-pkg/pkgcachegen.h diff --git a/apt-pkg/pkgcachegen.h b/apt-pkg/pkgcachegen.h index 328d296bf..21a4a6a09 100644 --- a/apt-pkg/pkgcachegen.h +++ b/apt-pkg/pkgcachegen.h @@ -26,7 +26,9 @@ #include #include -#include +#if __cplusplus >= 201103L +#include +#endif class FileFd; class pkgSourceList; @@ -41,10 +43,13 @@ class APT_HIDDEN pkgCacheGenerator /*{{{*/ APT_HIDDEN map_stringitem_t WriteStringInMap(const char *String, const unsigned long &Len); APT_HIDDEN map_pointer_t AllocateInMap(const unsigned long &size); - std::map strMixed; - std::map strSections; - std::map strPkgNames; - std::map strVersions; + // Dirty hack for public users that do not use C++11 yet +#if __cplusplus >= 201103L + std::unordered_map strMixed; + std::unordered_map strSections; + std::unordered_map strPkgNames; + std::unordered_map strVersions; +#endif friend class pkgCacheListParser; typedef pkgCacheListParser ListParser;