[net.lang.c] va_apply

kendall@talcott.UUCP (Sam Kendall) (11/19/84)

> How about another addition to <varargs.h>, which, given a function,
> its return type, and one of the (partially-used) va_list's, passes
> the remaining arguments referred to by the va_list to the function?
>   retval = va_apply( printf, int, nextarg );
> Obviously, va_apply is a macro, but it usually needs a library routine
> written in (shudder) assembler to copy and build another argument list.
> 
> ...
> 
> (Yes, we have implemented va_apply, and I have used it)
>                Kevin Martin, UofW Software Development Group

I don't think va_apply can be specified portably.  How does va_apply
know how many args are left, and what types they are?  How are you even
going to pass that information?  A table of types?  Too cumbersome to use
for printf.

	Sam Kendall	  {allegra,ihnp4,ima,amd}!wjh12!kendall
	Delft Consulting Corp.	    decvax!genrad!wjh12!kendall