Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!cs.utexas.edu!sun-barr!olivea!tymix!cirrusl!sunstorm!dhesi From: dhesi%cirrusl@oliveb.ATC.olivetti.com (Rahul Dhesi) Newsgroups: comp.lang.c Subject: Re: Do you use stdarg, varargs or ya-args? Message-ID: <3123@cirrusl.UUCP> Date: 10 May 91 16:17:56 GMT References: <2755@muffin.cme.nist.gov> <13041@dog.ee.lbl.gov> Sender: news@cirrusl.UUCP Reply-To: Rahul Dhesi Lines: 18 In <13041@dog.ee.lbl.gov> torek@elf.ee.lbl.gov (Chris Torek) defines this convenience macro: #if __STDC__ #define VASTART(ap, last) va_start(ap, last) #else #define VASTART(ap, last) va_start(ap) #endif I would like to know if there is anything in the ANSI C standard that guarantees that this will work. Using the Metaware High C compiler (which I mention in another posting), I found that it didn't. The High C compiler was doing some fancy token-pasting in its va_start macro, and that token pasting didn't work right if I defined my own macro that invoked va_start. It caused me three days of pain. -- Rahul Dhesi UUCP: oliveb!cirrusl!dhesi