diff options
author | Patrick Simianer <simianer@cl.uni-heidelberg.de> | 2012-05-18 13:16:03 +0200 |
---|---|---|
committer | Patrick Simianer <simianer@cl.uni-heidelberg.de> | 2012-05-18 13:16:03 +0200 |
commit | 47e9deff1c2cbd104d6e2822703cc83df625d8aa (patch) | |
tree | 72d2db8fc921a48e1b6306255ebbe5e7408e034b /utils/perfect_hash.h | |
parent | 37050e861de2b216d3a28f79e111b674c5d142ac (diff) | |
parent | 05b86961fa7e04d47cf729ea27e27c527f895da0 (diff) |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'utils/perfect_hash.h')
-rw-r--r-- | utils/perfect_hash.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/utils/perfect_hash.h b/utils/perfect_hash.h index 8ac11f18..29ea48a9 100644 --- a/utils/perfect_hash.h +++ b/utils/perfect_hash.h @@ -1,15 +1,16 @@ #ifndef _PERFECT_HASH_MAP_H_ #define _PERFECT_HASH_MAP_H_ -#include "config.h" +#include <vector> +#include <boost/utility.hpp> -#ifndef HAVE_CMPH -#error libcmph is required to use PerfectHashFunction +#ifdef HAVE_CONFIG_H +#include "config.h" #endif -#include <vector> -#include <boost/utility.hpp> +#ifdef HAVE_CMPH #include "cmph.h" +#endif class PerfectHashFunction : boost::noncopyable { public: @@ -18,7 +19,9 @@ class PerfectHashFunction : boost::noncopyable { size_t operator()(const std::string& key) const; size_t number_of_keys() const; private: +#ifdef HAVE_CMPH cmph_t *mphf_; +#endif }; #endif |