Path: utzoo!attcan!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!mips!decwrl!ads.com!sparkyfs!mckenney From: mckenney@sparkyfs.istc.sri.com (Paul Mckenney) Newsgroups: comp.lang.c++ Subject: Re: Byte padding question Message-ID: <32619@sparkyfs.istc.sri.com> Date: 8 Sep 90 18:07:05 GMT References: <1477@lupine.NCD.COM> Reply-To: mckenney@perth.itstd.sri.com.UUCP (Paul E. McKenney) Distribution: comp Organization: SRI International, Menlo Park, CA 94025 Lines: 11 In article <1477@lupine.NCD.COM> rfg@NCD.COM (Ron Guilmette) writes: >In article keving@r4.uk.ac.man.cs (Kevin Glynn) writes: >Well, you can't stop it. As I recollect, the reason that it is happening >is that Bjarne though that it would be a good idea to insure that each >element of each array in any given program should have a unique address. One reason for wanting this is to avoid a divide-by-zero fault in response to (&a[20]-&a[0]): recall that the subtraction operation for pointers subtracts the values and then divides by the length of an individual array element. Thanx, Paul