
On Thu, Nov 15, 2012 at 12:51 PM, Marshall Clow <mclow.lists@gmail.com>wrote:
On Nov 15, 2012, at 12:41 PM, "Phil Endecott" < spam_from_boost_dev@chezphil.org> wrote:
I'm about to check in some new functionality into the string_algo
Marshall Clow wrote: library; an implementation of string_ref.
A string_ref is a non-owning reference to a string. It is implemented
as a {pointer, length} pair, and is exceedingly useful
when parsing, and manipulating strings in "read-only" ways.
I mistyped: A string_ref is a non-owning reference to a contiguous sequence of characters.
How is this different from (say) contiguous_range< char > / contiguous_range< char const > ? I can imagine a contiguous_range<T> that wraps a pair of T*s, which would seem to be a simple generalization of your proposed string_ref. - Jeff