Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!ccu.umanitoba.ca!herald.usask.ca!alberta!ubc-cs!uw-beaver!cornell!batcomputer!caen!uakari.primate.wisc.edu!samsung!uunet!decwrl!deccrl!news.crl.dec.com!nntpd.lkg.dec.com!tkou02.enet.dec.com!jit533!diamond From: diamond@jit533.swstokyo.dec.com (Norman Diamond) Newsgroups: comp.std.c Subject: Re: so how do I do it? (was Re: call to revolt) Message-ID: <1991Jun28.040841.28901@tkou02.enet.dec.com> Date: 28 Jun 91 04:08:41 GMT References: <1991Jun27.115736.18417@tkou02.enet.dec.com> <16561@smoke.brl.mil> Sender: usenet@tkou02.enet.dec.com (USENET News System) Reply-To: diamond@jit533.enet@tkou02.enet.dec.com (Norman Diamond) Organization: Digital Equipment Corporation Japan , Tokyo Lines: 12 In article <16561@smoke.brl.mil> gwyn@smoke.brl.mil (Doug Gwyn) writes: >In article <1991Jun27.115736.18417@tkou02.enet.dec.com> diamond@jit533.enet@tkou02.enet.dec.com (Norman Diamond) writes: >>>and then (struct foo *)p->c or (struct foo *)p->u >>This is legal. >Actually, no. ((struct foo *)p)->c is the way to write this. >You want to cast the pointer, not the char member. Sorry. I probably messed up the syntax on a few other lines too. -- Norman Diamond diamond@tkov50.enet.dec.com If this were the company's opinion, I wouldn't be allowed to post it. Permission is granted to feel this signature, but not to look at it.