From: Greg King (gngking_at_erols.com)
Date: 2005-04-12 06:07:10
From: Ullrich von Bassewitz; on Date: April 01, 2005, at 06:45 AM -0400 > > Fortunately, there's an official ISO C standard named > "ISO/IEC 9899:1999 (E)"; and, among a lot of other, very interesting > things, it says in chapter 6.7.8 "Initialization", paragraph 10: > ---------------------------------------------------------------------- > 10 If an object that has automatic storage duration is not initialized > explicitly, its value is indeterminate. If an object that has static > storage duration is not initialized explicitly, then: > > - if it has pointer type, it is initialized to a null pointer; > > - if it has arithmetic type, it is initialized to (positive or > unsigned) zero; > > - if it is an aggregate, every member is initialized (recursively) > according to those rules; > > - if it is a union, the first named member is initialized > (recursively) according to those rules. > ---------------------------------------------------------------------- If the second named member of a union is longer than the first one, then what happens to the extra space? Is it indeterminate? Message was sent through the cbm-hackers mailing list
Archive generated by hypermail pre-2.1.8.