Article View: comp.std.c
Article #2425Representation Clauses
From: Karl Keyte
Date: Wed, 13 Feb 1991 13:14
Date: Wed, 13 Feb 1991 13:14
18 lines
943 bytes
943 bytes
How flexible are ANSI? I.e. is 'C's standardisation fixed?
I feel that 'C' is missing data alignment representation clauses in
structures. I would like to be able to do something like:
struct ALIGN_TEST
{
int a at 0;
char b at 4;
float c at 8;
}
in order to force the offset of the elements. This then enables
structures to provide truly portable messages on machines with
different structure alignments. For example, the above structure
is not the same on a Sun-3 and a Sun-4 (Sparc).
???
Technical Details
Message-ID:
<91042.160311KKEYTE@ESOC.BITNET>Path:
arc1-ca.pugleaf.net!utzoo!mnetor!tmsoft!torsqnt!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!wuarchive!uwm.edu!psuvax1!psuvm!esoc!kkeyteShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!mnetor!tmsoft!torsqnt!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!wuarchive!uwm.edu!psuvax1!psuvm!esoc!kkeyte From: KKEYTE@ESOC.BITNET (Karl Keyte) Newsgroups: comp.std.c Subject: Representation Clauses Message-ID: <91042.160311KKEYTE@ESOC.BITNET> Date: 13 Feb 91 13:14:19 GMT Lines: 18 Organisation: European Space Operation Centre (E.S.O.C)