|
|
coherent
va_arg() Variable Arguments va_arg() Return pointer to next argument in argument list #iinncclluuddee <ssttddaarrgg.hh> _t_y_p_e_n_a_m_e *vvaa_aarrgg(_l_i_s_t_p_t_r, _t_y_p_e_n_a_m_e) vvaa_lliisstt _l_i_s_t_p_t_r, _t_y_p_e_n_a_m_e; vvaa_aarrgg returns a pointer to the next argument in an argument list. It can be used with functions that take a variable number of arguments, such as pprriinnttff or ssccaannff, to help write such functions portably. It is always used with vvaa_eenndd and vvaa_ssttaarrtt within a function that takes a variable number of arguments. _l_i_s_t_p_t_r is of type vvaa_lliisstt, which is defined in the header ssttddaarrgg.hh. This object must first be initialized by the macro vvaa_ssttaarrtt. _t_y_p_e_n_a_m_e is the name of the type for which vvaa_aarrgg is to return a pointer. For example, if you wish vvaa_aarrgg to return a pointer to an integer, _t_y_p_e_n_a_m_e should be of type iinntt. vvaa_aarrgg can only handle ``standard'' data types, i.e., those data types that can be transformed to pointers by appending an asterisk `*'. ***** Example ***** For an example of this macro, see the entry for vvaarriiaabbllee aarrgguummeennttss. ***** See Also ***** vvaarriiaabbllee aarrgguummeennttss ***** Notes ***** If there is no next argument for vvaa_aarrgg to handle, or if _t_y_p_e_n_a_m_e is incorrect, then the behavior of vvaa_aarrgg is undefined. The ANSI Standard demands that vvaa_aarrgg be implemented only as a macro. If its macro definition is suppressed within a program, its behavior is undefined. COHERENT Lexicon Page 1
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.