Call a function FUNC exactly once, optionally providing it with argument ARG.
This is an extension of the standard function call_once.
- If ARG is given, it must be compatible with type
void*
and is passed to FUNC as an argument. In this case FUNC must have the prototype void FUNC(void*)
.
- If ARG is omitted FUNC should have the prototype
void FUNC(void)
, i.e not take any argument.
- If the field
p00_init
is initialized with an appropriate function, the FUNC can also be omitted and p00_init
is then called instead.
- See also
- p99_once_flag
Definition at line 202 of file p99_threads.h.