diff --git a/include/boost/functional/hash/hash.hpp b/include/boost/functional/hash/hash.hpp index 4927a01..1ffbc24 100644 --- a/include/boost/functional/hash/hash.hpp +++ b/include/boost/functional/hash/hash.hpp @@ -28,6 +28,10 @@ #include #endif +#if BOOST_WORKAROUND(__SUNPRO_CC, <= 0x590) +#include +#endif + namespace boost { std::size_t hash_value(bool); @@ -214,7 +218,9 @@ namespace boost reinterpret_cast(v)); #else std::size_t x = static_cast( - reinterpret_cast(v)); + boost::is_function::value ? + reinterpret_cast((void*) v) : + reinterpret_cast(v)); #endif return x + (x >> 3); }