Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!ames!haven!adm!smoke!gwyn From: gwyn@smoke.brl.mil (Doug Gwyn) Newsgroups: comp.lang.c Subject: Re: Func Protos with K&R Func Defs Message-ID: <15354@smoke.brl.mil> Date: 28 Feb 91 16:32:41 GMT References: <11614@jpl-devvax.JPL.NASA.GOV> <1991Feb28.021715.18153@athena.mit.edu> Organization: U.S. Army Ballistic Research Laboratory, APG, MD. Lines: 11 In article <1991Feb28.021715.18153@athena.mit.edu> jik@athena.mit.edu (Jonathan I. Kamens) writes: > In ANSI C, a function declaration must match its definition. That means >that if the declaration is prototyped, then the definition must also be >prototyped, with the same types; if the declaration is not prototyped, then >the definition cannot be prototyped either. This is not true. The types must be compatible, but subject to that constraint the use of "old-style definitions" is compatible with the use of prototypes. (Basically, this means that the declared parameter types must be those resulting from default argument promotion, i.e. "widened" types.)