From mboxrd@z Thu Jan 1 00:00:00 1970 From: erik quanstrom Date: Tue, 22 Sep 2009 14:58:28 -0400 To: fernanbolando@mailc.net, 9fans@9fans.net Message-ID: <09dd2940addf4ad34b64bb04c2b9d06f@brasstown.quanstro.net> In-Reply-To: <<1d5d51400909221149u32faccd7ue23a538afa523a23@mail.gmail.com>> References: <<1d5d51400909221149u32faccd7ue23a538afa523a23@mail.gmail.com>> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [9fans] zero length arrays in gcc Topicbox-Message-UUID: 757d0b4c-ead5-11e9-9d60-3106f5b1d025 > pcc does not allow this since zero lenth array is another gcc > extension. I tried declaring it as > > static unsigned startLabel[]; > > The resulting bytecode can then be compiled however it will only > crash. I traced it a pointer that tries to read an unallocated section > in memory. the only thing that makes sense is static unsigned startLabel0; static unsigned startLabel[] = &startLabel0 this might not work. one can't rule out deep and dark magic with gcc. - erik