Path: utzoo!attcan!uunet!lll-winken!lll-lcc!ames!mailrus!uflorida!haven!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn ) Newsgroups: comp.lang.c Subject: Re: register volatile Message-ID: <9290@smoke.BRL.MIL> Date: 6 Jan 89 05:48:49 GMT References: <141@bms-at.UUCP> <275@twwells.uucp> <15166@mimsy.UUCP> <15304@mimsy.UUCP> Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 15 In article <15304@mimsy.UUCP>, chris@mimsy.UUCP (Chris Torek) writes: > For portable code, you must avoid `register volatile', because current > systems (not dpANS-conformant, but still useful, such as SunOS) will > use something like > #define volatile /*empty*/ But that's clearly wrong in the first place. When back-porting to a pre-ANSI C environment, all uses of "volatile" (there shouldn't be many) have to be carefully checked to determine just why "volatile" was necessary, and adjustments made (if possible). There is no viable alternative! P.S. I do plant the above definition in pre-ANSI C environments (although I can't recall using it), but I don't expect it to "do the right thing" automatically, because it can't.