Article View: gnu.gcc.bug
Article #936Is "...", instead of ",..." legal ?
From: Scott Humphreys
Date: Thu, 13 Aug 1992 20:46
Date: Thu, 13 Aug 1992 20:46
20 lines
1228 bytes
1228 bytes
In various books describing the expansion to ANSI-C, one of the differences is described as the inclusion of the ",..." operator for function prototypes [ meaning that a variable number of arguments follow- e.g. int printf (const char *, ...); ] My question is: is this legal : int foo (...); That is - can I legally declare a function with none or many arguments, or does it HAVE to have at least one argument. This came up because gcc version 2.2.2 let me do it, but gave a warning when used with the -pedantic option. Another tool I used (gnu GCT version 1.3) bombed on this construct. Thanks for your time - I trust this isn't a FAQ... [individually cross posted to comp.lang.c as well] Regards, Scott
Technical Details
Message-ID:
<9208130546.AA21241@megadata.mega.oz.au>Path:
arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!ames!elroy.jpl.nasa.gov!swrinde!mips!darwin.sura.net!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!megadata.mega.oz.AU!scottShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!ames!elroy.jpl.nasa.gov!swrinde!mips!darwin.sura.net!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!megadata.mega.oz.AU!scott From: scott@megadata.mega.oz.AU (Scott Humphreys) Newsgroups: gnu.gcc.bug Subject: Is "...", instead of ",..." legal ? Message-ID: <9208130546.AA21241@megadata.mega.oz.au> Date: 13 Aug 92 20:46:43 GMT Sender: gnulists@ai.mit.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 20 Approved: bug-gcc@prep.ai.mit.edu