Newsgroups: comp.lang.c
Path: utzoo!henry
From: henry@zoo.toronto.edu (Henry Spencer)
Subject: Re: initialization of automatic structures/unions
Message-ID: <1991Mar3.003644.19731@zoo.toronto.edu>
Organization: U of Toronto Zoology
References: <13599@life.ai.mit.edu> <1991Mar2.000247.11318@sctc.com>
Date: Sun, 3 Mar 1991 00:36:44 GMT

In article <1991Mar2.000247.11318@sctc.com> stachour@sctc.com (Paul Stachour) writes:
>>Can someone give me a good reason why initializing automatic
>>structures/unions is illegal?
>
>    Because according to the rules of initialization:
>Initializers follow the sames rules for type and conversion as do
>assignment statements, and one can't assign "constant structures"
>or "constant arrays" in C.

Oh really?  Initialization of static structs has been possible since the
dawn of time in C, which makes your statement complete nonsense.  Please
get your facts straight before you post.  You don't help the credibility
of your Ada-good-C-bad claims by such gross errors.

The issue at hand is why Mr. Vistima can do this for statics but not for
automatics; the answer is "because his compiler doesn't implement ANSI C".
-- 
"But this *is* the simplified version   | Henry Spencer @ U of Toronto Zoology
for the general public."     -S. Harris |  henry@zoo.toronto.edu  utzoo!henry
