next up previous contents index
Next: Variable argument list Up: Send signal Previous: Send signal

The raise function

The function raise replaces the Base Document's kill function. The latter has an extra argument which refers to the ``process ID'' affected by the signal. Since the execution model of the Standard does not deal with multi-processing, the Committee deemed it preferable to introduce a function which requires no (dummy) process argument. The Committee anticipates that IEEE 1003 will wish to standardize the kill function in the POSIX specification.

4 8 Variable Arguments<stdarg.h> <stdarg.h>

For a discussion of argument passing issues, see .7.1.

These macros, modeled after the UNIX <varargs.h> macros, have been added to enable the portable implementation in C of library functions such as printf and scanf (see .9.6). Such implementation could otherwise be difficult, considering newer machines that may pass arguments in machine registers rather than using the more traditional stack-oriented methods.

The definitions of these macros in the Standard differ from their forebears: they have been extended to support argument lists that have a fixed set of arguments preceding the variable list.

va_start and va_arg must exist as macros, since va_start uses an argument that is passed by name and va_arg uses an argument which is the name of a data type. Using #undef on these names leads to undefined behavior.

addThe va_list type is not necessarily assignable. However, a function can pass a pointer to its initialized argument list object, as noted below.add

4 8 1


Pete Jinks
Fri Jan 19 12:31:56 GMT 1996