signal

Defined in header <signal.h> void (*signal( int sig, void (*handler) (int))) (int); Sets the error handler for signal sig. The signal handler can be set so that default handling will occur, signal is ignored, or an user-defined function is called. When signal handler is set to a function and a signal occurs, it is implementation defined whether signal(sig, SIG_DFL) will be executed immediately before the start of signal handler. Also, the implementation can prevent some imp

feraiseexcept

Defined in header <<fenv.h>> int feraiseexcept( int excepts ); (since C99) Attempts to raise all floating point exceptions listed in excepts (a bitwise OR of the floating point exception macros). If one of the exceptions is FE_OVERFLOW or FE_UNDERFLOW, this function may additionally raise FE_INEXACT. The order in which the exceptions are raised is unspecified, except that FE_OVERFLOW and FE_UNDERFLOW are always raised before FE_INEXACT. Parameters excepts - bi

External and tentative definitions

At the top level of a translation unit (that is, a source file with all the #includes after the preprocessor), every C program is a sequence of declarations, which declare functions and objects with external linkage. These declarations are known as external declarations because they appear outside of any function. extern int n; // external declaration with external linkage int b = 1; // external definition with external linkage static const char *c = "abc"; // external definition with intern

fputc

Defined in header <stdio.h> int fputc( int ch, FILE *stream ); int putc( int ch, FILE *stream ); Writes a character ch to the given output stream stream. putc() may be implemented as a macro and evaluation stream more than once, so the corresponding argument should never be an expression with side effects. Internally, the character is converted to unsigned char just before being written. Parameters ch - character to be written stream - output stream

atomic_signal_fence

Defined in header <stdatomic.h> void atomic_signal_fence( memory_order order ); (since C11) Establishes memory synchronization ordering of non-atomic and relaxed atomic accesses, as instructed by order, between a thread and a signal handler executed on the same thread. This is equivalent to std::atomic_thread_fence, except no CPU instructions for memory ordering are issued. Only reordering of the instructions by the compiler is suppressed as order instructs. For example, wr

enum

Usage declaration of an enumeration type

Generic selection

Provides a way to choose one of several expressions at compile time, based on a type of a controlling expression. Syntax _Generic ( controlling-expression , association-list ) (since C11) where association-list is a comma-separated list of associations, each of which has the syntax. type-name : expression default : expression where. type-name - any complete object type that isn't variably-modified (that is, not VLA or pointer to VLA). controlling-expression -

wcslen

Defined in header <wchar.h> size_t wcslen( const wchar_t *str ); (1) (since C95) size_t wcsnlen_s(const wchar_t *str, size_t strsz); (2) (since C11) 1) Returns the length of a wide string, that is the number of non-null wide characters that precede the terminating null wide character. 2) Same as (1), except that the function returns zero if str is a null pointer and returns strsz if the null wide character was not found in the first strsz wide characters of src As a

mtx_init

Defined in header <threads.h> int mtx_init( mtx_t* mutex, int type ); (since C11) Creates a new mutex object with type. The object pointed to by mutex is set to an identifier of the newly created mutex. type must have one of the following values: mtx_plain - a simple, non-recursive mutex is created. mtx_timed - a non-recursive mutex, that supports timeout, is created. mtx_plain | mtx_recursive - a recursive mutex is created. mtx_timed | mtx_recursive - a recursive mu

aligned_alloc

Defined in header <stdlib.h> void *aligned_alloc( size_t alignment, size_t size ); (since C11) Allocate size bytes of uninitialized storage whose alignment is specified by alignment. The size parameter must be an integral multiple of alignment. aligned_alloc is thread-safe: it behaves as though only accessing the memory locations visible through its argument, and not any static storage. A previous call to free or realloc that deallocates a region of memory synchronizes-with