Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.milw.wisc.edu!lll-winken!uunet!auspex!guy From: guy@auspex.auspex.com (Guy Harris) Newsgroups: comp.windows.x Subject: Re: bug in XCopyArea() of X11R3 Xsun server Message-ID: <1652@auspex.auspex.com> Date: 18 May 89 18:24:44 GMT References: <8905171605.AA16290@expo.lcs.mit.edu> Reply-To: guy@auspex.auspex.com (Guy Harris) Organization: Auspex Systems, Santa Clara Lines: 24 >Richard suggested putting in ifdef code for sparc's >to fix a design bug in the sparc architecture. >In fact he should just complain to his compiler supplier >for not supporting ANSI C. ANSI C is quite clear >that the result of a shift of 32 is 0. The December 7, 1988 ANSI C draft, at least, is quite clear that the result of a shift of 32 is *undefined*; if you want, I can cite chapter and verse. I tend to doubt that this changed in the version of the standard proposed to X3J11. >I would not want to see people defensively coding >all their shifts in this fashion because one >machine got it wrong. It will penalize all the >machines that got it right. More than one machine "got it wrong"; the 80386 - you know, the one used by YOUR COMPANY's high-end PS/2 machines - also "got it wrong" (check out the 80386 Programmer's Reference Manual). Unless the proposed ANSI C standard differs from the December 7, 1988 draft, people had damn well better code defensively. BTW, if you use "#if"s, it only penalizes people porting the code, not the machines that got it right.