Boost logo

Boost :

From: Peter Dimov (pdimov_at_[hidden])
Date: 2020-11-29 16:19:52

Jeff Garland wrote:

> I can give you a very concrete one -- from_iso_string in date_time. It's
> signature takes a const std::string&. If I have an std::string_view, then
> I have to unnecessarily construct a string to call this function -- which
> harms performance and is ugly.

The answer here is to take a string_view that is constructible from all
StringLike types, including std::string_view and boost::string_view.

boost::string_view could have been this type, but Marshall refuses to add
conversions to it, so everybody needs to roll his own. Or perhaps we need to
add one to Core so Marshall's one can be kept pristine and in its original
shrink wrap.

Boost list run by bdawes at, gregod at, cpdaniel at, john at