From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9577 invoked by alias); 8 Nov 2002 18:36:02 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 9561 invoked by uid 71); 8 Nov 2002 18:36:01 -0000 Date: Fri, 08 Nov 2002 10:36:00 -0000 Message-ID: <20021108183601.9560.qmail@sources.redhat.com> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, From: "Christian Ehrhardt" Subject: Re: c/8506: 3.3 (1104) disallowing omission of parameters in fn def Reply-To: "Christian Ehrhardt" X-SW-Source: 2002-11/txt/msg00424.txt.bz2 List-Id: The following reply was made to PR c/8506; it has been noted by GNATS. From: "Christian Ehrhardt" To: jdonner0@earthlink.net Cc: gcc-gnats@gcc.gnu.org Subject: Re: c/8506: 3.3 (1104) disallowing omission of parameters in fn def Date: Fri, 8 Nov 2002 19:35:28 +0100 On Fri, Nov 08, 2002 at 05:52:24PM -0000, jdonner0@earthlink.net wrote: > gcc now makes it an error to omit parameter names, eg > > int foo(int /* note, omitted parameter name*/){} > now gives an error. > > $ gcc foo.c > foo.c: In function `foo': > foo.c:1: error: parameter name omitted This behaviour seems to be mandated by the standard. 6.9.1[#5] states: If the declarator includes a parameter type list, the declaration of each parameter shall include an identifier, except for the special case of a parameter list consisting of a single parameter of type void, in which case there shall not be an identifier. No declaration list shall follow. regards Christian -- THAT'S ALL FOLKS!