> I'm curious; most of the wide character functions have parameters that
> are equivalent to their multi-byte versions. This permits you to
> re-#define things nicely and conditionally compile using multi-byte or
> wide characters. But the format specifiers are different for wide
> character strings regardless. Wide character strings are %ls vs. %s.
> Why didn't wprintf and friends use %s for wide character strings to
> complete the abstraction?

I've found its generally useless to write programs that support both
wide and mulbibyte characters internally. You're better off picking one
or the other and using it consistently.

I recommend using utf-8 internally and for string literals and comments,
and converting to/from locale-encoding on i/o. (Many programs will need
no changes to meet this requirement.) Its better to ignore the whole
misbegotten path of wide character c-lib funtions.

C++ is not really compatible with utf-32 or utf-16: for example you
cannot use them natively in string literals.

--
Linux-UTF8:   i18n of Linux on all levels
Archive:      http://mail.nl.linux.org/linux-utf8/

Reply via email to