Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!henry From: henry@utzoo.UUCP (Henry Spencer) Newsgroups: net.lang.c Subject: Re: Un-alignment in structures Message-ID: <5345@utzoo.UUCP> Date: Tue, 26-Mar-85 12:45:33 EST Article-I.D.: utzoo.5345 Posted: Tue Mar 26 12:45:33 1985 Date-Received: Tue, 26-Mar-85 12:45:33 EST References: <9434@brl-tgr.ARPA>, <4258@umcp-cs.UUCP> Organization: U of Toronto Zoology Lines: 22 > ... unaligned struct foo *foop; { > > Is foop a pointer to an unaligned struct foo, or is it an unaligned > pointer to struct foo? (The proposed "const" modifier has this > problem, by the way.) No it doesn't, and the problem could be solved for "unaligned" in the same way. Here's how it works for const: const char *pcc; /* ptr to const char */ char *const cpc; /* const ptr to char */ It is agreed that the syntax is a bit ugly, but then C declaration syntax has never been beautiful. (None of this is to be taken to constitute an endorsement of "unaligned". I tend to side with the people who think its contribution to portability would be marginal, perhaps even negative [it deludes people into thinking that their stuff is portable, when it's not].) -- Henry Spencer @ U of Toronto Zoology {allegra,ihnp4,linus,decvax}!utzoo!henry