Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site gumby.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!genrad!panda!talcott!harvard!seismo!uwvax!gumby!g-frank From: g-frank@gumby.UUCP Newsgroups: net.lang.c Subject: Re: parens around sizeof arg Message-ID: <314@gumby.UUCP> Date: Mon, 25-Feb-85 08:26:18 EST Article-I.D.: gumby.314 Posted: Mon Feb 25 08:26:18 1985 Date-Received: Wed, 27-Feb-85 21:08:22 EST References: <8048@brl-tgr.ARPA> <607@ncoast.UUCP> <512@rlgvax.UUCP> Organization: U of Wisconsin CS Dept Lines: 21 > > Style for you guys, necessity for others. The only time I use sizeof is > > in such expressions as, "sizeof(struct foo)"; and our compiler doesn't > > realize that "struct" gets a following name, so "sizeof struct foo" gets > > me a syntax error. > > That's a "sizeof(type)", not a "sizeof thing", and the parentheses are > necessary in that case. > Oh, how nice. Something else for experts in C to know so they can feel superior to the novices. Never have one, consistent way to use a language construct when you can have two to demonstrate your mastery of the arcana. -- Dan Frank Q: What's the difference between an Apple MacIntosh and an Etch-A-Sketch? A: You don't have to shake the Mac to clear the screen.