Path: utzoo!utgpu!attcan!uunet!lll-winken!ames!haven!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn ) Newsgroups: comp.lang.c Subject: Re: #define volatile /*empty*/ Message-ID: <9302@smoke.BRL.MIL> Date: 7 Jan 89 01:43:28 GMT References: <141@bms-at.UUCP> <275@twwells.uucp> <15166@mimsy.UUCP> <9290@smoke.BRL.MIL> <15318@mimsy.UUCP> <9300@smoke.BRL.MIL> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 14 In article <9300@smoke.BRL.MIL> gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) writes: >I think that's the only PORTABLE use, but certainly a standard- >conforming program CAN use the "volatile" type qualifier in other >(nonportable) contexts. It occurs to me that I may not have made this clear enough. A portable, standard-conforming program does not become nonportable or non-conforming upon addition of "volatile" qualifiers (assuming of course the addition is done according to the type rules). It is only the actual reliance upon the property of volatility that would be nonportable. (e.g. device register) int main() { volatile int i; return i = 0; } is a portable, standard-conforming program.