This is the mail archive of the
libstdc++@sources.redhat.com
mailing list for the libstdc++ project.
libstc++-v3 basic_string & multibyte strings
- To: libstdc++ at sources dot redhat dot com
- Subject: libstc++-v3 basic_string & multibyte strings
- From: Gianni Mariani <marianig at orconet dot com>
- Date: Mon, 24 Jul 2000 12:59:28 -0700
- Reply-To: marianig at orconet dot com
I would really like to have efficient multibyte support for
basic_string.
Simple methods like :
mblen, mbtowc etc
Or a character iterator e.g.
template < yadda > class string_utf8 : public basic_string< yadda > {
inline Character_Iterator Character_begin()
{
.... generate a character iterator ...
Character_iterator would be able to do things like read_char which
would convert a utf-8 character to a ucs-4 character and move the
pointer approprite bits.
}
// convert to utf 16
inline operator string_utf16()
{
... Do a conversion to utf-16 ...
}
// convert to ucs_4
inline operator string_ucs4()
{
... Do a conversion to UCS 4
}
};
You get the drift. There would be classes that supported using the
local mbstowcs etc as well as hard coded unicode conversions.
Anyone done anything in this area ?
Any interest ?
Any suggestions to achieve blinding performance ?