🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #432

Re: scope of actual parameters

#432
From: D'Arcy Cain
Date: Tue, 08 Aug 1989 18:48
19 lines
935 bytes
In article <8936@june.cs.washington.edu>, pardo@june.cs.washington.edu (David Keppel) writes:
> My *impression* is that actual parameter names are local to the
> function.  My dpANS-compliant compiler (gcc version 1.34) complains on
> the following program:
> 
>     typedef int foo;
>     m (foo){}
> 
>     foo.c: parameter name omitted
> 
> 
typedef creates a new data type not a parameeter name so the above response
is correct.  the declaration is exactly the same as the following:

	m (int){}

Which is obviously incorrect.

D'Arcy J.M. Cain
Technical Details
Message-ID: <776@bbm.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!yunexus!stpl!bbm!darcy
References: <8936@june.cs.washington.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!yunexus!stpl!bbm!darcy
From: darcy@bbm.UUCP (D'Arcy Cain)
Newsgroups: comp.std.c
Subject: Re: scope of actual parameters
Summary: typedef creates a type not a name
Message-ID: <776@bbm.UUCP>
Date: 8 Aug 89 18:48:13 GMT
Article-I.D.: bbm.776
References: <8936@june.cs.washington.edu>
Organization: BBM Bureau of Measurement, Toronto
Lines: 19