Path: utzoo!mnetor!uunet!lll-winken!lll-lcc!ames!mailrus!nrl-cmf!cmcl2!brl-adm!brl-smoke!gwyn From: gwyn@brl-smoke.ARPA (Doug Gwyn ) Newsgroups: comp.lang.c Subject: Re: Signedness of chars Message-ID: <7413@brl-smoke.ARPA> Date: 4 Mar 88 13:05:40 GMT References: <23209@ucbvax.BERKELEY.EDU> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 13 In article <23209@ucbvax.BERKELEY.EDU> hilfingr@tully.Berkeley.EDU.berkeley.edu (Paul Hilfinger) writes: >Does anyone know of widely-used programs that depend on the type >`char' being signed? That is, how many programs would break if >`unsigned char' and `char' were the same type? A large number of PDP-11 UNIX programs were in this category, for example much of the GPS-based PWB/Graphics. By now, I think the version in use here has all these bugs fixed. (NOT the AT&T way, which was to use #ifdef u3b2 rather than change the code to work portably.) The most common portability error in this regard is char c; while ((c = getchar()) != EOF) ...