On Fri, Mar 02, 2007 at 03:23:01PM +0100, Lapo Luchini wrote: > Seems a good & clean approach to me. > I'll pursue it ASAP (a few days worth of bus-travels from and to my > workplace). > I have to remember that "skip" in this case is not "++pos", but rather > "pos+=utf8_char_len(pos);" (for an hypothetical utf_char_len function).
This is a nice optimization (though not the end of the world if we don't have it; the only impact is that we might put the wrong number of question marks in the output, oh well), and we have various utf8 character handling stuff -- check the utf8 validation code and the idna library. The important thing, though, is to make sure that whatever you do still works even with random ill-formed utf8, and when we're not converting out of utf8 at all... -- Nathaniel -- Damn the Solar System. Bad light; planets too distant; pestered with comets; feeble contrivance; could make a better one myself. -- Lord Jeffrey _______________________________________________ Monotone-devel mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/monotone-devel
