Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rutgers!ames!ucbcad!faustus From: faustus@ucbcad.berkeley.edu (Wayne A. Christopher) Newsgroups: comp.lang.misc Subject: Re: Check the Arg Count Message-ID: <1220@ucbcad.berkeley.edu> Date: Tue, 13-Jan-87 12:22:08 EST Article-I.D.: ucbcad.1220 Posted: Tue Jan 13 12:22:08 1987 Date-Received: Tue, 13-Jan-87 23:45:23 EST References: <1634@enea.UUCP> <594@mcgill-vision.UUCP> <1639@enea.UUCP> Organization: CAD Group, U.C. Berkeley Lines: 16 In article <1639@enea.UUCP>, sommar@enea.UUCP (Erland Sommarskog) writes: > To get I/O-routines (or whatever scanf() is) with variable parameter lists, > there seems to be four ways: > 1) Make them standard routines recognized by the compiler. The best alter- > native. Specially in a small langauge like C. > 2) Introduce a syntax that allows this. Possible, but not very attrcative. > 3) Skip checking of parameter count. To be straight: Ridiculous. > 4) Forget the whole thing. You're assuming that there is no use for variable argument lists besides printf() and scanf(). This isn't true -- I use them all the time... (Well, now and then....) Your solution (1) doesn't address this problem, solution (2) is already in C (it's called "varargs"), (3) is what C used to do, and (4) is unacceptable. Wayne