Article View: comp.std.c
Article #85Re: Character arrays in structures and address alignment -- any standard?
From: Christopher R Volpe
Date: Tue, 04 Aug 1992 15:37
Date: Tue, 04 Aug 1992 15:37
34 lines
2162 bytes
2162 bytes
In article <14382@ksr.com>, jfw@ksr.com (John F. Woods) writes: |> volpe@bart.NoSubdomain.NoDomain (Christopher R Volpe) writes: |> >There are no "two interpretations". That's the whole point. The "other |> >interpretation" was shot down by the strictly conforming program that |> >prints different results under the non-literal interpretation. |> |> No. The program given was strictly conforming if and only if the "implied" |> forbidding of "unnecessary" padding is real. I claim that there is nothing True. I wasn't clear enough. The "other interpretation" that I was referring to (the invalid one) is the one that says that unnecessary padding can be show to be acceptable via the "as-if" rule. |> in the rest of the Standard that allows one to deduce this (unlike the "all |> structure pointers are the same size" rule), and that the words "may not" do |> not appear in either |> |> "There may be unnamed padding within a structure object, but not |> at its beginning, as necessary to achieve the appropriate alignment." Ok, there is definitely room for interpretation here. For some reason I remember the wording being something like "...only as necessary to achieve", which would forbid unnecessary padding. Anyway, I stand corrected. |> As I said, whoever wrote the Rationale also appears to believe that structures |> may have internal padding that strict parsimony would reject. Agreed. -- ================== Chris Volpe G.E. Corporate R&D volpecr@crd.ge.com
Technical Details
Message-ID:
<1992Aug4.153751.27148@crd.ge.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!crdgw1!rdsunx.crd.ge.com!bart!volpeReferences:
<Bs5pMJ.3nM@twwells.com> <7022@skye.ed.ac.uk> <1992Jul31.010941.7282@crd.ge.com> <7039@skye.ed.ac.uk> <1992Aug3.005338.1488@crd.ge.com> <14382@ksr.com>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!crdgw1!rdsunx.crd.ge.com!bart!volpe From: volpe@bart.NoSubdomain.NoDomain (Christopher R Volpe) Newsgroups: comp.std.c Subject: Re: Character arrays in structures and address alignment -- any standard? Message-ID: <1992Aug4.153751.27148@crd.ge.com> Date: 4 Aug 92 15:37:51 GMT References: <Bs5pMJ.3nM@twwells.com> <7022@skye.ed.ac.uk> <1992Jul31.010941.7282@crd.ge.com> <7039@skye.ed.ac.uk> <1992Aug3.005338.1488@crd.ge.com> <14382@ksr.com> Sender: volpe@bart (Christopher R Volpe) Reply-To: volpe@ausable.crd.ge.com Organization: GE Corporate Research & Development Lines: 34 Nntp-Posting-Host: bart.crd.ge.com