diff --git a/include/boost/utility/string_view.hpp b/include/boost/utility/string_view.hpp index 63f7a8f..bc5055a 100644 --- a/include/boost/utility/string_view.hpp +++ b/include/boost/utility/string_view.hpp @@ -27,6 +27,7 @@ #include #include #include +#include #include namespace boost { @@ -129,7 +130,7 @@ namespace boost { len_ -= n; } - BOOST_CONSTEXPR void swap(basic_string_view& s) BOOST_NOEXCEPT { + /*BOOST_CONSTEXPR*/ void swap(basic_string_view& s) BOOST_NOEXCEPT { std::swap(ptr_, s.ptr_); std::swap(len_, s.len_); } diff --git a/test/string_view_test3.cpp b/test/string_view_test3.cpp index f0b9bbd..7311c73 100644 --- a/test/string_view_test3.cpp +++ b/test/string_view_test3.cpp @@ -464,8 +464,9 @@ namespace int cpp_main(int argc, char* argv[]) { - typedef boost::string_view::traits_type string_traits; - typedef boost::string_view::const_pointer const_pointer; + // verify traits_type and const_pointer typedefs compile OK + BOOST_TEST(boost::string_view::traits_type::eq('x', 'x')); + BOOST_TEST_EQ(sizeof(boost::string_view::const_pointer), sizeof(&argc)); swap_test(); copy_test();