// Copyright (c) 2011 // Antony Polukhin // // Distributed under the Boost Software License, Version 1.0. (See // accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) #include "./config.hpp" #ifdef TEST_STD_INCLUDES # include #else # include #endif #include #include #include int main() { typedef boost::variant variant_type; HASH_NAMESPACE::hash hasher; variant_type bool_variant1 = true; variant_type bool_variant2 = false; variant_type int_variant = 1; variant_type float_variant = 1.0; variant_type uint_variant = static_cast(1); BOOST_TEST(hasher(bool_variant1) != hasher(bool_variant2)); BOOST_TEST(hasher(bool_variant1) == hasher(bool_variant1)); BOOST_TEST(hasher(int_variant) != hasher(uint_variant)); BOOST_TEST(hasher(float_variant) != hasher(uint_variant)); return boost::report_errors(); }