Must sizeof(int) exceed sizeof(char) in hosted environments?
D. Chadwick Gibbons
chad at csd4.csd.uwm.edu
Wed Sep 13 06:06:46 AEST 1989
In article <9487 at cbnews.ATT.COM> mark at cblpf.ATT.COM (Mark Horton) writes:
|The obvious reason why you would want big characters (other than tiny
|8 bit machines) is to support eastern character sets, such as the
|Japanese Kanji.
Exactly why the indentifier wchar_t was placed into the pANS. A
small note of this is given in the latter parts of K&R. wchar_t is
implementation defined to be the largest value any particular character set
can within a given locale.
|By the way, some other character sets (such as Chinese) don't fit in
|16 bits. Assuming that since int=long that characters will always be
|smaller than int may not be safe.
Possibly safe, but definately not portable programming.
More information about the Comp.std.c
mailing list