Article View: gnu.gcc.bug
Article #6160Re: Neat new bug!
From: David Kastrup
Date: Wed, 20 Nov 1996 00:00
Date: Wed, 20 Nov 1996 00:00
26 lines
1714 bytes
1714 bytes
seebs@intran.xerox.com (Peter Seebach) writes:
> The declaration
> =09int foo(void a[2]) {
> =09}
> is perfectly correct, and declares foo to take a *pointer to void* as
> an argument. gcc -ansi -pedantic -Wall should not reject it. (I could
> easily see a warning as appropriate, but the message
> >t.c:3: declaration of `a' as array of voids
> is clearly not correct; no parameter is ever an array.)
Personally, I think the error message correct: one declares the types
of ones' arguments, and that arrays get converted to pointers is a
technicality. At least this is the way I feel it should be, which, of
course, signifies nothing.
So I presume somebody ought to whip out some standard and quote it so
as to make us all happy.
--
David Kastrup Phone: +49-234-700-5570
Email: dak@neuroinformatik.ruhr-uni-bochum.de Fax: +49-234-709-4209
Institut f=FCr Neuroinformatik, Universit=E4tsstr. 150, 44780 Bochum, Germa=
ny
Technical Details
Message-ID:
<m2enhpf5u7.fsf@mailhost.neuroinformatik.ruhr-uni-bochum.de>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<9611191727.AA00679@moose.intran.xerox.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 113d02,4c4e632fb8296479 X-Google-Attributes: gid113d02,public From: dak@fsnif.neuroinformatik.ruhr-uni-bochum.de (David Kastrup) Subject: Re: Neat new bug! Date: 1996/11/20 Message-ID: <m2enhpf5u7.fsf@mailhost.neuroinformatik.ruhr-uni-bochum.de> X-Deja-AN: 197635933 sender: dak@maloche.rz.ruhr-uni-bochum.de references: <9611191727.AA00679@moose.intran.xerox.com> content-type: text/plain; charset=ISO-8859-1 organization: Institut fuer Neuroinformatik, Ruhr-Universitaet Bochum, Germany x-gateway: relay5.UU.NET from bug-gcc to gnu.gcc.bug; Wed, 20 Nov 1996 08:02:56 EST mime-version: 1.0 (generated by tm-edit 7.93) newsgroups: gnu.gcc.bug