Path: utzoo!attcan!uunet!kddlab!ccut!titcca!sragwa!wsgw!socslgw!diamond From: diamond@csl.sony.co.jp (Norman Diamond) Newsgroups: comp.std.c Subject: sizeof ((rehash *) 0)->again Message-ID: <11138@riks.csl.sony.co.jp> Date: 16 Nov 89 13:38:53 GMT Reply-To: diamond@ws.sony.junet (Norman Diamond) Organization: Sony Computer Science Laboratory Inc., Tokyo, Japan Lines: 12 According to section 3.2.2.3, page 38, an integral constant expression with the value 0, or such an expression cast to type void *, is a null pointer constant. SUCH AN EXPRESSION CAST TO TYPE rehash * IS NOT CITED IN THIS MANNER. Section 3.3.4 says that the result has the named type, i.e. rehash *. Therefore the semantics of -> select a member of the pointed-to type, and sizeof takes its size. -- Norman Diamond, Sony Corp. (diamond%ws.sony.junet@uunet.uu.net seems to work) Should the preceding opinions be caught or | James Bond asked his killed, the sender will disavow all knowledge | ATT rep for a source of their activities or whereabouts. | licence to "kill".