Imported Upstream version 1.72.0
[platform/upstream/boost.git] / libs / histogram / test / utility_str.hpp
1 // Copyright 2019 Hans Dembinski
2 //
3 // Distributed under the Boost Software License, Version 1.0.
4 // (See accompanying file LICENSE_1_0.txt
5 // or copy at http://www.boost.org/LICENSE_1_0.txt)
6
7 #ifndef BOOST_HISTOGRAM_TEST_UTILITY_STR_HPP
8 #define BOOST_HISTOGRAM_TEST_UTILITY_STR_HPP
9
10 #include <sstream>
11 #include <string>
12
13 template <class T>
14 std::string str(const T& t) {
15   std::ostringstream os;
16   os << t;
17   return os.str();
18 }
19
20 #endif