Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!samsung!uakari.primate.wisc.edu!uflorida!novavax!twwells!bill From: bill@twwells.com (T. William Wells) Newsgroups: comp.lang.c Subject: Re: Zero Length Arrays Allowed in C Standard? Message-ID: <1989Dec14.182646.5481@twwells.com> Date: 14 Dec 89 18:26:46 GMT References: <2298@jato.Jpl.Nasa.Gov> <11715@smoke.BRL.MIL> <480@codonics.COM> <1989Dec2.210042.12668@twwells.com> <8129@cg-atla.UUCP <70188@psuecl.bitnet> <1498@utkcs2.cs.utk.edu> Organization: None, Ft. Lauderdale, FL Lines: 20 In article <1498@utkcs2.cs.utk.edu> battle@alphard.cs.utk.edu (David Battle) writes: : Is the order of elements of a structure guaranteed to be the same in memory : as in the program? That is, given: : : struct foo { : int a; : int b; : }; : : struct foo bar; : : Is &bar.a guaranteed to be < &bar.b? I don't think that K&R guarantees it but it might. The dpANS does, however, guarantee it. See 3.5.2.1. --- Bill { uunet | novavax | ankh | sunvice } !twwells!bill bill@twwells.com