From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1014db,cb40752a27f3d651 X-Google-Attributes: gid1014db,public X-Google-Thread: 1164f8,cb40752a27f3d651 X-Google-Attributes: gid1164f8,public X-Google-Thread: fee84,cb40752a27f3d651 X-Google-Attributes: gidfee84,public From: cwr@cts.com (Will Rose) Subject: Re: comma operator: C compiler bug or bogus usage? Date: 1999/04/15 Message-ID: <7f5stm$6a8$6@nusku.cts.com>#1/1 X-Deja-AN: 466914381 References: <7f567v$sp1$1@news.iastate.edu> <5u8PBMkHV$73G$1@joerch.org> Followup-To: comp.lang.c,comp.unix.osf.osf1,comp.sys.dec X-Complaints-To: usenet@nusku.cts.com X-Trace: nusku.cts.com 924219126 6472 205.163.0.7 (15 Apr 1999 23:32:06 GMT) Organization: CTS Network Services (CTSNET), San Diego, CA NNTP-Posting-Date: 15 Apr 1999 23:32:06 GMT Newsgroups: comp.lang.c,comp.unix.osf.osf1,comp.sys.dec Joerg Czeranski (jc@joerch.org) wrote: [...] : gcc has a different handling of "," and IMHO it violates the standard : in that respect. Even gcc -ansi -pedantic doesn't emit a diagnostic : for this error (it violates the constraint in 6.3.16.1: Simple assignment, : referred to by 6.5.8: Initialization): : char weekday[7] = { "Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun" }; : (That's an actual example of something a friend who is just learning C : stumbled over.) I'm suprised at that; I get 'number of initialisers cannot be greater than the number of aggregate members' with the compiler I use. It's the sort of thing you'd want checked, too. Will cwr@crash.cts.com