| DocBook: The Definitive Guide 2.0.17 (Alpha)

# varargs

$Revision: 1666 $

$Date: 2002-06-12 07:19:37 -0400 (Wed, 12 Jun 2002) $

varargs — An empty element in a function synopsis indicating a variable number of arguments

## Synopsis

### Content Model

    varargs ::=
    EMPTY

### Attributes

Common attributes

## Description

`VarArgs` indicates that a function takes a variable number of arguments.

### Processing expectations

The `VarArgs` element produces generated text that indicates that the function takes a variable number of arguments. The exact generated text may vary. One common result is “`(…)`”.

### Parents

These elements contain varargs: `funcprototype`.

## See Also

`funcdef`, `funcparams`, `funcprototype`, `funcsynopsisinfo`, `function`, `paramdef`, `parameter`, `returnvalue`, `void`.

## Examples

    <!DOCTYPE funcsynopsis PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
              "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
    <funcsynopsis>
    <funcsynopsisinfo>
    #include &lt;varargs.h&gt;
    </funcsynopsisinfo>
    <funcprototype>
      <funcdef>int <function>max</function></funcdef>
      <varargs/>
    </funcprototype>
    </funcsynopsis>

    #include <varargs.h>

`int max(` | ...`)`; |

For additional examples, see also `funcsynopsis`.

userinput |  | variablelist

Copyright © 1999, 2000, 2001, 2002, 2003 O'Reilly & Associates, Inc. All rights reserved.