Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!snorkelwacker.mit.edu!bloom-picayune.mit.edu!news From: scs@adam.mit.edu (Steve Summit) Newsgroups: comp.lang.c Subject: Re: lint (was: Funny mistake) Message-ID: <1991Mar28.084403.29369@athena.mit.edu> Date: 28 Mar 91 08:44:03 GMT References: <1991Mar23.043408.5260@athena.mit.edu> <1991Mar24.165719.26908@druid.uucp> Sender: news@athena.mit.edu (News system) Reply-To: scs@adam.mit.edu Organization: Thermal Technologies, Cambridge, MA Lines: 18 In article lamont@amdahl.uts.amdahl.com (Duane Richard LaMont) writes: >In article <1991Mar24.165719.26908@druid.uucp> darcy@druid.uucp (D'Arcy J.M. Cain) writes: >>I simply make sure that within a file a function is not used until it >>has been defined. This in effect makes it a prototype for itself. > >I thought this was a good idea too, but it didn't work for me on the >first prototyping compiler I ever used (SCO XENIX, forget the version >number). It behaved as if I had declared the function without >prototyping it (i.e. the return type was known, but not the argument >count and types). > >Are prototyping compilers supposed to treat a function as prototyped >following that function's definition? Yes. Steve Summit scs@adam.mit.edu