ANSI C prototypes

Steve Resnick stever at Octopus.COM
Sat Nov 3 12:39:08 AEST 1990


In article <1990Nov2.030556.27759 at ccu.umanitoba.ca> salomon at ccu.umanitoba.ca (Dan Salomon) writes:
>In article <RJC.90Nov1145211 at brodie.uk.ac.ed.cstr> rjc at uk.ac.ed.cstr (Richard Caley) writes:
>>In article <1906 at necisa.ho.necisa.oz> boyd at necisa.ho.necisa.oz (Boyd Roberts) writes:
>>
>> > Right on!  The function prototypes are just stupid.
>> > I shouldn't have to type:
>> >      extern gore	*good(const char *vomit);
>> > to get the functionality of type checking of function arguments.
>> > The compiler and loader should do it.  
>>
>> I want my errors when I compile things, not when some poor guy tries
>> to use it.
>>
>
>You are both right.  Repeatedly typing function prototypes is a tedious
>waste of time, but we really would like type errors reported at compile
>time.
>
>A possible solution would be to have a utility for building libraries
>of function prototypes from source code.  The compiler could check
>source code usage against usage in this library.  The linker would have
>to repeat the check to make sure that the prototype library didn't get
>out of synch with the object library.
>-- 
>

	Some C compilers do this for you. Microsoft C 6.0 will, as an option
	generate declarations (prototypes) to stdout when asked to. This has
	saved me the tedium of typing all those prototypes in myself! :)


Cheers!
Steve


-- 
----------------------------------------------------------------------------
steve.resnick at f105.n143.z1.FIDONET.ORG - or - apple!camphq!105!steve.resnick
Flames, grammar errors, spelling errrors >/dev/nul
The Asylum OS/2 BBS - (408)263-8017 IFNA 1:143/105.0



More information about the Comp.lang.c mailing list