Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!ucbvax!pasteur!dog.ee.lbl.gov!elf.ee.lbl.gov!torek From: torek@elf.ee.lbl.gov (Chris Torek) Newsgroups: comp.std.c Subject: Re: vs. function prototypes Keywords: usage Message-ID: <14423@dog.ee.lbl.gov> Date: 18 Jun 91 19:04:06 GMT References: <25353@oolong.la.locus.com> <159364@pyramid.pyramid.com> <1991Jun18.145823.2512@cbnewsk.att.com> Reply-To: torek@elf.ee.lbl.gov (Chris Torek) Distribution: na Organization: Lawrence Berkeley Laboratory, Berkeley Lines: 27 X-Local-Date: Tue, 18 Jun 91 12:04:06 PDT >In article <159364@pyramid.pyramid.com> markhall@pyrps5.pyramid.com >(Mark Hall) writes: >> #ifdef __STDC__ >> void foo(char *format, ...) >> #else >> void foo(format, va_alist) char *format; va_dcl >> #endif [and on from there] In article <1991Jun18.145823.2512@cbnewsk.att.com> hansen@pegasus.att.com (Tony L. Hansen) writes: >The above form for usage is wrong. ... This is correct; however, I have used the above, and continue to use it, in 4BSD code, with the excuse that: a) it is far clearer; and b) if your varargs does not handle it, you can probably obtain an ANSI C implementation and use the __STDC__ code anyway. In other words, we are not willing to bend over backwards (for compatibility) until it hurts, only until it is mildly uncomfortable. :-) Chris -- In-Real-Life: Chris Torek, Lawrence Berkeley Lab CSE/EE (+1 415 486 5427) Berkeley, CA Domain: torek@ee.lbl.gov