diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2014-03-30 12:39:02 +0000 |
|---|---|---|
| committer | Alex Valavanis <valavanisalex@gmail.com> | 2014-03-30 12:39:02 +0000 |
| commit | c238cf70cf7cd2b3ad6e347076e15d74304294c2 (patch) | |
| tree | 6feb9ac3fd6abe1c3c197f159116fa249c4a7bb8 | |
| parent | Fix some mismatched tags (diff) | |
| download | inkscape-c238cf70cf7cd2b3ad6e347076e15d74304294c2.tar.gz inkscape-c238cf70cf7cd2b3ad6e347076e15d74304294c2.zip | |
End support for obsolete GNU hash. Supported either natively, through TR1 or Boost now
Fixed bugs:
- https://launchpad.net/bugs/1269346
(bzr r13231)
| -rw-r--r-- | configure.ac | 1 | ||||
| -rw-r--r-- | src/util/unordered-containers.h | 31 |
2 files changed, 0 insertions, 32 deletions
diff --git a/configure.ac b/configure.ac index c470c4535..7a19599cc 100644 --- a/configure.ac +++ b/configure.ac @@ -183,7 +183,6 @@ else fi AC_CHECK_HEADER([boost/unordered_set.hpp], [AC_DEFINE(HAVE_BOOST_UNORDERED_SET, 1, [Boost unordered_set (Boost >= 1.36)])], []) -AC_CHECK_HEADER([ext/hash_set], [AC_DEFINE(HAVE_EXT_HASH_SET, 1, [Legacy GNU ext/hash_set])], []) # Test whether GCC emits a spurious warning when using boost::optional # If yes, turn off strict aliasing warnings to reduce noise diff --git a/src/util/unordered-containers.h b/src/util/unordered-containers.h index 98c2fa3c9..b92f2e7ea 100644 --- a/src/util/unordered-containers.h +++ b/src/util/unordered-containers.h @@ -69,37 +69,6 @@ struct hash<Glib::ustring> : public std::unary_function<Glib::ustring, std::size } }; } // namespace boost - -#elif defined(HAVE_EXT_HASH_SET) - -# include <functional> -# include <ext/hash_set> -# include <ext/hash_map> -# define INK_UNORDERED_SET __gnu_cxx::hash_set -# define INK_UNORDERED_MAP __gnu_cxx::hash_map -# define INK_HASH __gnu_cxx::hash - -#include <cstddef> - -namespace __gnu_cxx { -// hash function for pointers -// TR1 and Boost have this defined by default, __gnu_cxx doesn't -template<typename T> -struct hash<T *> : public std::unary_function<T *, std::size_t> { - std::size_t operator()(T *p) const { - // Taken from Boost - std::size_t x = static_cast<std::size_t>(reinterpret_cast<std::ptrdiff_t>(p)); - return x + (x >> 3); - } -}; - -template <> -struct hash<Glib::ustring> : public std::unary_function<Glib::ustring, std::size_t> { - std::size_t operator()(Glib::ustring const &s) const { - return hash<std::string>()(s.raw()); - } -}; -} // namespace __gnu_cxx #endif #else |
