Path: utzoo!mnetor!uunet!husc6!bloom-beacon!gatech!mcnc!rti!xyzzy!throopw From: throopw@xyzzy.UUCP (Wayne A. Throop) Newsgroups: comp.lang.c Subject: Re: Optimization, volatile (was Re: volatile) Message-ID: <839@xyzzy.UUCP> Date: 6 May 88 15:02:31 GMT References: <13074@brl-adm.ARPA> <2003@rtech.UUCP> <503@wsccs.UUCP> <536@sol.warwick.ac.uk> Organization: Data General, RTP NC. Lines: 30 > cudcv@daisy.warwick.ac.uk (Rob McMahon) >> terry@wsccs.UUCP (Every system needs one) >> [...doing things like "volatile" is...] why #pragma was invented. > It's been said before, but some people seem to have missed it ... how do > you use #pragma to specify all of: > volatile int *p; > int *volatile p; > volatile int *volatile p; I've made this reply before, but some people seem to have missed it... you do it like so: using keywords: using pragmas: int is volatile int *p; int *p; volatile #pragma volatile *p pointer is int *volatile p; int *p; volatile #pragma volatile p both are volatile int *volatile p; int *p; volatile #pragma volatile p, *p "It works for me." -- He wonders if he too might have made a similar mistake. --- "Seen and Not Seen" by Talking Heads from "Remain in Light" -- Wayne Throop !mcnc!rti!xyzzy!throopw