Varargs problem

Aaron Wohl aw0g+ at andrew.cmu.edu
Sat Aug 26 09:10:03 AEST 1989


Bobg,

As a rabid varargs user, I can attest to the wonders of never giving
anything fancy to varags.  Always use a typedef.  How about:

#include <varargs.h>

typedef (*int_func)();

void mumble(va_alist)
va_dcl
{
        va_list ap;
        int_func fn;
        va_start(ap);
        fn=va_arg(ap,int_func);
        frotz(fn);
}

Aaron



More information about the Comp.lang.c mailing list