Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2021-10-18 01:10:05


Andrey Semashev wrote:
> Add an overload like this:
>
> #if !defined(BOOST_NO_CXX17_HDR_STRING_VIEW)
>
> inline std::string_view api_function( std::string_view str )
> {
> boost::string_view res = api_function(
> boost::string_view(str.data(), str.size()));
> return std::string_view(res.data(), res.size());
> }
>
> #endif

As I said, all code that used to call the function with a std::string or
with a string literal is now broken under C++17.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk