
29 Dec
2012
29 Dec
'12
7:24 p.m.
On 29 December 2012 18:08, Olaf van der Spek <ml@vdspek.org> wrote:
On Sat, Dec 29, 2012 at 6:33 PM, Daniel James <dnljms@gmail.com> wrote:
If I wasn't clear enough, I'm not suggesting supporting arbitrary iterators. Just std::basic_string::const_iterator and boost::basic_string_ref::const_iterator. I suppose I should have included raw char pointers as well.
Can't you use the (const char*, size_t) overload with (s.data(), s.size())? Or, what's the exact use case?
In quickbook I use string_ref to pass around substrings of quickbook and xml source code. I use iterators everywhere. Using iterators like this is standard practice in STL based code.