Path: utzoo!mnetor!uunet!seismo!sundc!pitstop!sun!decwrl!labrea!aurora!eos!ames!hao!husc6!linus!philabs!gcm!dc From: dc@gcm (Dave Caswell) Newsgroups: comp.sys.mac Subject: Re: LightSpeed C 2.15 putchar fix, hope done in LSC3.0, etc. Message-ID: <413@white.gcm> Date: 25 Feb 88 12:44:22 GMT References: <6813@drutx.ATT.COM> <6814@drutx.ATT.COM> Reply-To: dc@white.UUCP (Dave Caswell) Organization: Greenwich Capital Markets, Greenwich, CT Lines: 22 )Nontheless, I think it's very important that this usage and the reasons )be well understood, not glossed over with the 'most C compilers promote )passed char arguments to ints anyway'. VERY bad practice to depend on )anything of the sort; it's the sort of foolishness that makes people )hate C and its programmers. And it's completely un-necessary. )Makes a lot more sense just to do things right. ) )When you get to C++, the world changes again, and though some )promotions remain, and others are added, there is a real mire pit )waiting if you try to make things work by such 'inner' details. )Trust me on this one. I trust K&R The C Programming Language. I quote p. 184 "First, any operands of type char or short are converted to int ..." This is the language definition. All C compilers opromost passed char arguments to ints, just as they make 3+4 equal to 7, and I depend on both things happening. Sorry to be so dogmatic, but I've read this stuff a >100 times and it isn't true.