--- N:\_tmp\string_generator.hpp.orig 2010-03-29 20:15:44.000000000 -0700 +++ N:\_tmp\string_generator.hpp 2011-05-26 17:59:01.000000000 -0700 @@ -6,12 +6,13 @@ // http://www.boost.org/LICENSE_1_0.txt) #ifndef BOOST_UUID_STRING_GENERATOR_HPP #define BOOST_UUID_STRING_GENERATOR_HPP #include +#include #include #include // for strlen, wcslen #include #include // for find #include @@ -38,13 +39,13 @@ struct string_generator { typedef uuid result_type; template uuid operator()(std::basic_string const& s) const { return operator()(s.begin(), s.end()); - }; + } uuid operator()(char const*const s) const { return operator()(s, s+std::strlen(s)); } uuid operator()(wchar_t const*const s) const { @@ -171,14 +172,15 @@ } else { throw_invalid(); } } void throw_invalid() const { - throw std::runtime_error("invalid uuid string"); + // FIXME: maybe this should use BOOST_THROW_EXCEPTION() instead? + throw_exception(std::runtime_error("invalid uuid string")); } }; }} // namespace boost::uuids #endif //BOOST_UUID_STRING_GENERATOR_HPP