
On Wed, 19 Jan 2011 18:44:44 -0800, Chad Nelson <chad.thecomfychair@gmail.com> wrote:
On Wed, 19 Jan 2011 14:32:31 -0800 Mostafa <mostafa_working_away@yahoo.com> wrote:
operator* has a long history of providing the contents of a variable, even in C, and is a lot less typing to boot. But if you have any technical arguments against it, I'm listening.
Can we stick to std::string conventions as closely as possible? It makes using whatever new string library that much easier, and clearer, and maintainable.
Is there a conventional way to get the data stored in an std::string? ;-)
On second thought, is there really a need to access the underlying data of utf8_t? I argue that having a view of the underlying data via iterators accomplishes just as much(*), and is more inline with the stl tradition of containers and iterators, not to mention the better encapsulation it affords the interface. Do clients really need to know, and potentially develop a dependency on, the fact that utf8_t (for now?) is really just a wrapper for std::string? (*) Granted there are legacy/existing C and C++ interfaces that require C style strings, and I guess that's what a potential utf8_t::c_str would be for. Mostafa