From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,974799d066e5d38e X-Google-Attributes: gid103376,public From: lutz@iks-jena.de (Lutz Donnerhacke) Subject: Re: Wide_Character vs. Interfaces.C.wchar_t Date: 1999/10/14 Message-ID: #1/1 X-Deja-AN: 536585476 Distribution: world Content-Transfer-Encoding: 8bit References: <87emez6nn6.fsf@deneb.cygnus.argh.org> Followup-To: poster Content-Type: text/plain; charset=ISO-8859-1 Organization: IKS GmbH Jena Mime-Version: 1.0 User-Agent: slrn/0.9.5.7 (UNIX) Newsgroups: comp.lang.ada Date: 1999-10-14T00:00:00+00:00 List-Id: * Keith Thompson wrote: >unsigned). As it happens, almost all existing C compilers use 8 bits >for char, so this doesn't tend to arise in real life. A lot of embedded controller compilers do have 32/64bit for a char. They can't deal with smaller values. We noticed it, because the C standard requires sizeof(char) to be one. So we have sizeof(char) == sizeof(short) == sizeof(int) == sizeof(long) == sizeof(long long) == 1 on this machine, causing the problem, that the following common construct stops on the input char -1: int c; while(EOF != (c = getchar())) ... F'up poster.