From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4709 invoked by alias); 18 Apr 2008 21:31:17 -0000 Received: (qmail 4641 invoked by uid 22791); 18 Apr 2008 21:31:11 -0000 X-Spam-Check-By: sourceware.org Received: from yw-out-1718.google.com (HELO yw-out-1718.google.com) (74.125.46.152) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 18 Apr 2008 20:53:46 +0000 Received: by yw-out-1718.google.com with SMTP id 6so430671ywa.26 for ; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Received: by 10.150.219.16 with SMTP id r16mr4256405ybg.198.1208552019175; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Received: by 10.151.41.21 with HTTP; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Message-ID: <7dee4710804181353u39bed374nda5ccf88c44f3645@mail.gmail.com> Date: Sat, 19 Apr 2008 04:54:00 -0000 From: "Igor Bukanov" To: "Jim Wilson" Subject: Re: GCC accepts dynamically-sized array in sizeof with -std=c89 Cc: gcc-help@gcc.gnu.org In-Reply-To: <4808E750.3050200@tuliptree.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <7dee4710804160352l7438e709t5fa3418199a3b03@mail.gmail.com> <4808E750.3050200@tuliptree.org> Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2008-04/txt/msg00263.txt.bz2 On 18/04/2008, Jim Wilson wrote: > Adding -pedantic does generate the warning. Perhaps you expected a warning > without -pedantic? If you read the docs carefully, you will see that > -std=c89 enables all features of that standard, but does not disable GNU > extensions to that standard. You need -pedantic for that. You are right, I have misted -pedantic and with -pedantic-errors the example does generated the error. Regards, Igor From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15505 invoked by alias); 19 Apr 2008 00:10:10 -0000 Received: (qmail 15462 invoked by uid 22791); 19 Apr 2008 00:10:09 -0000 X-Spam-Check-By: sourceware.org Received: from mail.gnu.org (HELO mx10.gnu.org) (199.232.76.166) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 18 Apr 2008 21:33:34 +0000 Received: from yw-out-1718.google.com ([74.125.46.156]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JmyAx-0000dc-Dt for gcc-help@gcc.gnu.org; Fri, 18 Apr 2008 17:31:19 -0400 Received: by yw-out-1718.google.com with SMTP id 6so436616ywa.26 for ; Fri, 18 Apr 2008 14:20:58 -0700 (PDT) Received: by 10.150.219.16 with SMTP id r16mr4256405ybg.198.1208552019175; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Received: by 10.151.41.21 with HTTP; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Message-ID: <7dee4710804181353u39bed374nda5ccf88c44f3645@mail.gmail.com> Date: Sat, 19 Apr 2008 07:03:00 -0000 From: "Igor Bukanov" To: "Jim Wilson" Subject: Re: GCC accepts dynamically-sized array in sizeof with -std=c89 Cc: gcc-help@gcc.gnu.org In-Reply-To: <4808E750.3050200@tuliptree.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <7dee4710804160352l7438e709t5fa3418199a3b03@mail.gmail.com> <4808E750.3050200@tuliptree.org> X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 2) Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2008-04/txt/msg00264.txt.bz2 Message-ID: <20080419070300.7M4pnKn3NeHvJoZ8yQMQ5s22r1n1AsKULsAovjHM-Jo@z> On 18/04/2008, Jim Wilson wrote: > Adding -pedantic does generate the warning. Perhaps you expected a warning > without -pedantic? If you read the docs carefully, you will see that > -std=c89 enables all features of that standard, but does not disable GNU > extensions to that standard. You need -pedantic for that. You are right, I have misted -pedantic and with -pedantic-errors the example does generated the error. Regards, Igor From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4529 invoked by alias); 19 Apr 2008 01:40:41 -0000 Received: (qmail 4511 invoked by uid 22791); 19 Apr 2008 01:40:40 -0000 X-Spam-Check-By: sourceware.org Received: from mx10.gnu.org (HELO mx10.gnu.org) (199.232.76.166) by sourceware.org (qpsmtpd/0.31) with ESMTP; Sat, 19 Apr 2008 01:40:21 +0000 Received: from yw-out-1718.google.com ([74.125.46.156]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JmyAx-0000dc-Dt for gcc-help@gcc.gnu.org; Fri, 18 Apr 2008 17:31:19 -0400 Received: by yw-out-1718.google.com with SMTP id 6so436616ywa.26 for ; Fri, 18 Apr 2008 14:20:58 -0700 (PDT) Received: by 10.150.219.16 with SMTP id r16mr4256405ybg.198.1208552019175; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Received: by 10.151.41.21 with HTTP; Fri, 18 Apr 2008 13:53:39 -0700 (PDT) Message-ID: <7dee4710804181353u39bed374nda5ccf88c44f3645@mail.gmail.com> Date: Sat, 19 Apr 2008 09:33:00 -0000 From: "Igor Bukanov" To: "Jim Wilson" Subject: Re: GCC accepts dynamically-sized array in sizeof with -std=c89 Cc: gcc-help@gcc.gnu.org In-Reply-To: <4808E750.3050200@tuliptree.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <7dee4710804160352l7438e709t5fa3418199a3b03@mail.gmail.com> <4808E750.3050200@tuliptree.org> X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 2) Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2008-04/txt/msg00265.txt.bz2 Message-ID: <20080419093300.fYkBJaJ1UOX2e38xKn2w3-unLvgt7i0o61in0_TzOIA@z> On 18/04/2008, Jim Wilson wrote: > Adding -pedantic does generate the warning. Perhaps you expected a warning > without -pedantic? If you read the docs carefully, you will see that > -std=c89 enables all features of that standard, but does not disable GNU > extensions to that standard. You need -pedantic for that. You are right, I have misted -pedantic and with -pedantic-errors the example does generated the error. Regards, Igor