diff options
Diffstat (limited to 'src')
186 files changed, 662 insertions, 2 deletions
diff --git a/src/ctype.c b/src/ctype.c index a5eb75c..c97016e 100644 --- a/src/ctype.c +++ b/src/ctype.c @@ -28,6 +28,8 @@ * @param c The character. * @return Whether the character is in * ['0', '9'], ['A', 'Z'], or ['a', 'z']. + * + * @since Always. */ int (isalnum)(int c) { @@ -43,6 +45,8 @@ int (isalnum)(int c) * @param c The character. * @return Whether the character is in * ['A', 'Z'] or ['a', 'z']. + * + * @since Always. */ int (isalpha)(int c) { @@ -58,6 +62,8 @@ int (isalpha)(int c) * * @param c The character. * @return Whether the character is a ' ' or a '\t'. + * + * @since Always. */ int (isblank)(int c) { @@ -73,6 +79,8 @@ int (isblank)(int c) * * @param c The character. * @return Whether the character is lower than ' '. + * + * @since Always. */ int (iscntrl)(int c) { @@ -87,6 +95,8 @@ int (iscntrl)(int c) * * @param c The character. * @return Whether the character is in ['0', '9']. + * + * @since Always. */ int (isdigit)(int c) { @@ -101,6 +111,8 @@ int (isdigit)(int c) * * @param c The character. * @return Whether the character is greater than ' '. + * + * @since Always. */ int (isgraph)(int c) { @@ -116,6 +128,8 @@ int (isgraph)(int c) * * @param c The character. * @return Whether the character is in ['a', 'z']. + * + * @since Always. */ int (islower)(int c) { @@ -132,6 +146,8 @@ int (islower)(int c) * @param c The character. * @return Whether the character is at least * as great as ' '. + * + * @since Always. */ int (isprint)(int c) { @@ -148,6 +164,8 @@ int (isprint)(int c) * * @param c The character. * @return Whether the character is a punctuation. + * + * @since Always. */ int (ispunct)(int c) { @@ -163,6 +181,8 @@ int (ispunct)(int c) * @param c The character. * @return Whether the character is a ' ', '\f', * '\n', '\r', '\t', or '\v'. + * + * @since Always. */ int (isspace)(int c) { @@ -178,6 +198,8 @@ int (isspace)(int c) * * @param c The character. * @return Whether the character is in ['A', 'Z']. + * + * @since Always. */ int (isupper)(int c) { @@ -195,6 +217,8 @@ int (isupper)(int c) * @param c The character. * @return Whether the character is in * ['0', '9'], ['A', 'Z'], or ['a', 'z']. + * + * @since Always. */ int (isxdigit)(int c) { @@ -218,6 +242,8 @@ int (isxdigit)(int c) * @return The character in lowercase. * Guaranteed to be unchanged if the * character already is in lowercase. + * + * @since Always. */ int (tolower)(int c) { @@ -240,6 +266,8 @@ int (tolower)(int c) * @return The character in uppercase. * Guaranteed to be unchanged if the * character already is in lowercase. + * + * @since Always. */ int (toupper)(int c) { @@ -255,6 +283,8 @@ int (toupper)(int c) * * @param c The character * @return Whether the character is an ASCII character. + * + * @since Always. */ int (isascii)(int c) { @@ -276,6 +306,8 @@ int (isascii)(int c) * * @param c The character. * @return The character with the 8:th bit cleared. + * + * @since Always. */ int (toascii)(int c) { @@ -286,6 +318,8 @@ int (toascii)(int c) /** * This function is identical to `tolower`. * It is provided for backwards-compatibility with SVID. + * + * @since Always. */ int _tolower(int c) { @@ -296,6 +330,8 @@ int _tolower(int c) /** * This function is identical to `tolower`. * It is provided for backwards-compatibility with SVID. + * + * @since Always. */ int _toupper(int c) { diff --git a/src/err/err.c b/src/err/err.c index f63d2a4..99b43e5 100644 --- a/src/err/err.c +++ b/src/err/err.c @@ -31,6 +31,8 @@ * @param status The exit status the process should have. * @param format Formatting-string for the warning. * @param ... Formatting-arguments. + * + * @since Always. */ void err(int status, const char* format, ...) { diff --git a/src/err/errx.c b/src/err/errx.c index d29f849..50f63b7 100644 --- a/src/err/errx.c +++ b/src/err/errx.c @@ -31,6 +31,8 @@ * @param status The exit status the process should have. * @param format Formatting-string for the warning. * @param ... Formatting-arguments. + * + * @since Always. */ void errx(int status, const char* format, ...) { diff --git a/src/err/verr.c b/src/err/verr.c index 2857c16..475efdb 100644 --- a/src/err/verr.c +++ b/src/err/verr.c @@ -33,6 +33,8 @@ * @param status The exit status the process should have. * @param format Formatting-string for the warning. * @param args Formatting-arguments. + * + * @since Always. */ void verr(int status, const char* format, va_list args) { diff --git a/src/err/verrx.c b/src/err/verrx.c index 4708264..12b4c72 100644 --- a/src/err/verrx.c +++ b/src/err/verrx.c @@ -32,6 +32,8 @@ * @param status The exit status the process should have. * @param format Formatting-string for the warning. * @param args Formatting-arguments. + * + * @since Always. */ void verrx(int status, const char* format, va_list args) { diff --git a/src/err/vwarn.c b/src/err/vwarn.c index 78676d4..782f2f1 100644 --- a/src/err/vwarn.c +++ b/src/err/vwarn.c @@ -30,6 +30,8 @@ * * @param format Formatting-string for the warning. * @param args Formatting-arguments. + * + * @since Always. */ void vwarn(const char* format, va_list args) { diff --git a/src/err/vwarnx.c b/src/err/vwarnx.c index c44e57a..7c29fa1 100644 --- a/src/err/vwarnx.c +++ b/src/err/vwarnx.c @@ -29,6 +29,8 @@ * * @param format Formatting-string for the warning. * @param args Formatting-arguments. + * + * @since Always. */ void vwarnx(const char* format, va_list args) { diff --git a/src/err/warn.c b/src/err/warn.c index de5c793..82bda4e 100644 --- a/src/err/warn.c +++ b/src/err/warn.c @@ -30,6 +30,8 @@ * * @param format Formatting-string for the warning. * @param ... Formatting-arguments. + * + * @since Always. */ void warn(const char* format, ...) { diff --git a/src/err/warnx.c b/src/err/warnx.c index d80dfd8..adc136f 100644 --- a/src/err/warnx.c +++ b/src/err/warnx.c @@ -30,6 +30,8 @@ * * @param format Formatting-string for the warning. * @param ... Formatting-arguments. + * + * @since Always. */ void warnx(const char* format, ...) { diff --git a/src/errno/variables.c b/src/errno/variables.c index e204a2c..9523b37 100644 --- a/src/errno/variables.c +++ b/src/errno/variables.c @@ -35,6 +35,8 @@ * or `argv[0]` is edited. * * This is a GNU and slibc extension. + * + * @since Always. */ char* program_invocation_name = NULL; @@ -46,6 +48,8 @@ char* program_invocation_name = NULL; * or `argv[0]` is edited. * * This is a GNU extension. + * + * @since Always. */ char* program_invocation_short_name = NULL; diff --git a/src/error/error.c b/src/error/error.c index 6b15c4c..496ce3c 100644 --- a/src/error/error.c +++ b/src/error/error.c @@ -35,6 +35,8 @@ * be printed. * @param format Formatting-string for a detailed description of what happend. * @param args Formatting-arguments for `format`. + * + * @since Always. */ void error(int status, int errnum, const char* format, ...) { diff --git a/src/error/error_at_line.c b/src/error/error_at_line.c index 9e9a79c..8b88df3 100644 --- a/src/error/error_at_line.c +++ b/src/error/error_at_line.c @@ -37,6 +37,8 @@ * @param linenum The line number of in the source code file where the error occurred. * @param format Formatting-string for a detailed description of what happend. * @param args Formatting-arguments for `format`. + * + * @since Always. */ void error_at_line(int status, int errnum, const char* filename, unsigned int linenum, const char* format, ...) diff --git a/src/error/variables.c b/src/error/variables.c index a31c970..b012921 100644 --- a/src/error/variables.c +++ b/src/error/variables.c @@ -27,6 +27,8 @@ * This is a GNU extension. * * @etymology (`error`)-subsystem: (message count). + * + * @since Always. */ volatile unsigned int error_message_count = 0; @@ -48,6 +50,8 @@ volatile unsigned int error_message_count = 0; * This is a GNU extension. * * @etymology (`error`)-subsystem: print (one) time (per line). + * + * @since Always. */ volatile int error_one_per_line = 1; @@ -62,6 +66,8 @@ volatile int error_one_per_line = 1; * This is a GNU extension. * * @etymology (`error`)-subsystem function: (print) the (prog)ram's (name). + * + * @since Always. */ void (*volatile error_print_progname)(void) = NULL; diff --git a/src/error/verror.c b/src/error/verror.c index a5a4551..3632f7c 100644 --- a/src/error/verror.c +++ b/src/error/verror.c @@ -34,6 +34,8 @@ * be printed. * @param format Formatting-string for a detailed description of what happend. * @param args Formatting-arguments for `format`. + * + * @since Always. */ void verror(int status, int errnum, const char* format, va_list args) { diff --git a/src/error/verror_at_line.c b/src/error/verror_at_line.c index dd51f30..ae6c566 100644 --- a/src/error/verror_at_line.c +++ b/src/error/verror_at_line.c @@ -42,6 +42,8 @@ * @param linenum The line number of in the source code file where the error occurred. * @param format Formatting-string for a detailed description of what happend. * @param args Formatting-arguments for `format`. + * + * @since Always. */ void verror_at_line(int status, int errnum, const char* filename, unsigned int linenum, const char* format, va_list args) diff --git a/src/inttypes/imaxabs.c b/src/inttypes/imaxabs.c index 25ed7b7..649cd47 100644 --- a/src/inttypes/imaxabs.c +++ b/src/inttypes/imaxabs.c @@ -31,6 +31,8 @@ * * @param value The integer. * @return The absolute value of the integer. + * + * @since Always. */ intmax_t (imaxabs)(intmax_t value) { diff --git a/src/inttypes/imaxdiv.c b/src/inttypes/imaxdiv.c index e4d0caa..978ace6 100644 --- a/src/inttypes/imaxdiv.c +++ b/src/inttypes/imaxdiv.c @@ -33,6 +33,8 @@ * the process will be killed by SIGFPE. * @return The quotient in `.quot`, and * the remainder in `.rem`. + * + * @since Always. */ imaxdiv_t imaxdiv(intmax_t numerator, intmax_t denominator) { diff --git a/src/libgen/basename_xpg.c b/src/libgen/basename_xpg.c index 267f3e2..d1bd49e 100644 --- a/src/libgen/basename_xpg.c +++ b/src/libgen/basename_xpg.c @@ -29,6 +29,8 @@ * of `filename` or, if `filename` is `NULL` * or is empty, a statically allocationed string, * so it must not freed or edited. + * + * @since Always. */ char* __xpg_basename(char* filename) { diff --git a/src/libgen/cleanname.c b/src/libgen/cleanname.c index db542cc..d3b884b 100644 --- a/src/libgen/cleanname.c +++ b/src/libgen/cleanname.c @@ -42,6 +42,8 @@ * if `filename` is `NULL` or does no contain a * non-trailing slash, a statically allocationed * string, so it must not freed or edited. + * + * @since Always. */ char* cleanname(char* filename) { diff --git a/src/libgen/dirname.c b/src/libgen/dirname.c index 3200b07..1b0a3d6 100644 --- a/src/libgen/dirname.c +++ b/src/libgen/dirname.c @@ -29,6 +29,8 @@ * or does no contain a non-trailing slash, * a statically allocationed string, so it * must not freed or edited. + * + * @since Always. */ char* dirname(char* filename) { diff --git a/src/malloc.c b/src/malloc.c index a66c062..c6c1629 100644 --- a/src/malloc.c +++ b/src/malloc.c @@ -91,6 +91,8 @@ static void* unaligned_malloc(size_t size) * indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* malloc(size_t size) { @@ -116,6 +118,8 @@ void* malloc(size_t size) * `errno` is set to indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* calloc(size_t elem_count, size_t elem_size) { @@ -152,6 +156,8 @@ void* calloc(size_t elem_count, size_t elem_size) * indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* mallocz(size_t size, int clear) { @@ -182,6 +188,8 @@ void* mallocz(size_t size, int clear) * indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* zalloc(size_t size) { @@ -215,6 +223,8 @@ void* zalloc(size_t size) * is returned and `errno` is set to indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* realloc(void* ptr, size_t size) { @@ -231,6 +241,8 @@ void* realloc(void* ptr, size_t size) * The process may crash if it does not point to the * beginning of a memory allocation on the heap. * However, if it is `NULL`, nothing will happen. + * + * @since Always. */ void free(void* ptr) { @@ -249,6 +261,8 @@ void free(void* ptr) * The process may crash if it does not point to the * beginning of a memory allocation on the heap. * However, if it is `NULL`, nothing will happen. + * + * @since Always. */ void cfree(void* ptr, ...) { @@ -280,6 +294,8 @@ void cfree(void* ptr, ...) * * @throws ENOMEM The process cannot allocate more memory. * @throws EINVAL If `boundary` is not a power of two. + * + * @since Always. */ void* memalign(size_t boundary, size_t size) { @@ -327,6 +343,8 @@ void* memalign(size_t boundary, size_t size) * * @throws ENOMEM The process cannot allocate more memory. * @throws EINVAL If `boundary` is not a power-of-two multiple of `sizeof(void*)`. + * + * @since Always. */ int posix_memalign(void** ptrptr, size_t boundary, size_t size) { @@ -354,6 +372,8 @@ int posix_memalign(void** ptrptr, size_t boundary, size_t size) * indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* valloc(size_t size) { @@ -377,6 +397,8 @@ void* valloc(size_t size) * indicate the error. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* pvalloc(size_t size) { @@ -416,6 +438,8 @@ void* pvalloc(size_t size) * * @throws ENOMEM The process cannot allocate more memory. * @throws EINVAL If `boundary` is not a power of two. + * + * @since Always. */ void* aligned_alloc(size_t boundary, size_t size) { @@ -433,6 +457,8 @@ void* aligned_alloc(size_t boundary, size_t size) * * @param segment The memory segment. * @return The size of the memory segment, 0 if `segment` is `NULL`. + * + * @since Always. */ size_t malloc_usable_size(void* segment) { diff --git a/src/slibc-alloc.c b/src/slibc-alloc.c index 5ae9cbd..9438b15 100644 --- a/src/slibc-alloc.c +++ b/src/slibc-alloc.c @@ -59,6 +59,8 @@ * override the memory segment with zeroes before freeing the allocation. * * @param segment The memory segment to free. + * + * @since Always. */ void fast_free(void* segment) { @@ -73,6 +75,8 @@ void fast_free(void* segment) * override the memory segment with zeroes before freeing the allocation. * * @param segment The memory segment to free. + * + * @since Always. */ void secure_free(void* segment) { @@ -103,6 +107,8 @@ void secure_free(void* segment) * implemented in slibc. It is however not guaranteed * that this will happen, undefined behaviour may be * invoked instead. + * + * @since Always. */ size_t allocsize(void* segment) { @@ -169,6 +175,8 @@ size_t allocsize(void* segment) * @return The new allocation, see `realloc` for more details. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* crealloc(void* ptr, size_t size) { @@ -185,6 +193,8 @@ void* crealloc(void* ptr, size_t size) * @return The new allocation, see `realloc` for more details. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* fast_realloc(void* ptr, size_t size) { @@ -201,6 +211,8 @@ void* fast_realloc(void* ptr, size_t size) * @return The new allocation, see `realloc` for more details. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* secure_realloc(void* ptr, size_t size) { @@ -229,6 +241,8 @@ void* secure_realloc(void* ptr, size_t size) * @return The new allocation, see `realloc` for more details. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* custom_realloc(void* ptr, size_t size, int clear_old, int clear_new, int clear_free) { @@ -258,6 +272,8 @@ void* custom_realloc(void* ptr, size_t size, int clear_old, int clear_new, int c * * @throws 0 `errno` is set to zero success if `NULL` is returned. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* extalloc(void* ptr, size_t size, enum extalloc_mode mode) { @@ -300,6 +316,8 @@ void* extalloc(void* ptr, size_t size, enum extalloc_mode mode) * @throws 0 `errno` is set to zero success if `NULL` is returned. * @throws EINVAL `mode` is invalid, or `boundary` is not a power of two. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* rememalign(void* ptr, size_t boundary, size_t size, enum rememalign_mode mode) { @@ -373,6 +391,8 @@ void* rememalign(void* ptr, size_t boundary, size_t size, enum rememalign_mode m * * @throws EINVAL `boundary` is not a power of two. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* naive_realloc(void* ptr, size_t boundary, size_t size) { @@ -394,6 +414,8 @@ void* naive_realloc(void* ptr, size_t boundary, size_t size) * * @throws 0 `malloc` is require to perform the action. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* naive_extalloc(void* ptr, size_t size) { @@ -419,6 +441,8 @@ void* naive_extalloc(void* ptr, size_t size) * on error (errno is set to describe the error.) * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ __GCC_ONLY(__attribute__((nonnull))) static inline void* falloc_realloc(void* ptr, size_t* ptrshift, size_t alignment, @@ -501,6 +525,8 @@ static inline void* falloc_realloc(void* ptr, size_t* ptrshift, size_t alignment * @throws 0 `new_size` is zero. * @throws EINVAL The arguments are invalid. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ void* falloc(void* ptr, size_t* ptrshift, size_t alignment, size_t old_size, size_t new_size, enum falloc_mode mode) diff --git a/src/slibc-error.c b/src/slibc-error.c index 26724f9..70a4e3c 100644 --- a/src/slibc-error.c +++ b/src/slibc-error.c @@ -44,6 +44,8 @@ * @param format Formatting-string for a description of the action that failed. `NULL` if * no description other than the location and `error_string` should be printed. * @param ... Formatting-arguments for `format`. + * + * @since Always. */ void slibc_perror(const char* progname, const char* filename, int linenum, const char* function, int* error_code, const char* error_string, const char* format, ...) diff --git a/src/slibc-human/escape.c b/src/slibc-human/escape.c index 9579f73..4296715 100644 --- a/src/slibc-human/escape.c +++ b/src/slibc-human/escape.c @@ -38,6 +38,8 @@ * @throws 0 `str` is `NULL`. * @throws EINVAL If `quote` is invalid. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ char* escape(const char* restrict str, char quote) { diff --git a/src/slibc-human/humanmode.c b/src/slibc-human/humanmode.c index 5dca887..6288433 100644 --- a/src/slibc-human/humanmode.c +++ b/src/slibc-human/humanmode.c @@ -35,6 +35,8 @@ * * @throws EINVAL If `mode` is invalid. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ char* humanmode(char* restrict buffer, mode_t perm, enum humanmode_mode mode) { diff --git a/src/slibc-human/humansize.c b/src/slibc-human/humansize.c index cabd9ab..ecebd26 100644 --- a/src/slibc-human/humansize.c +++ b/src/slibc-human/humansize.c @@ -244,6 +244,8 @@ static char* humansize_round(char* buffer, size_t bufsize, enum humansize_mode m * * @throws EINVAL If `mode` is invalid. * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ char* humansize(char* buffer, size_t bufsize, size_t size, enum humansize_mode mode, int detail, const char* restrict point, const char* restrict intraspacing, const char* restrict interspacing) diff --git a/src/slibc-human/machinemode.c b/src/slibc-human/machinemode.c index af8c4bb..13d123a 100644 --- a/src/slibc-human/machinemode.c +++ b/src/slibc-human/machinemode.c @@ -204,6 +204,8 @@ static inline int exact_numeric(mode_t* restrict mode, mode_t* restrict mask, co * @return Zero on success, -1 on error. * * @throws EINVAL If `str` is not parseable. + * + * @since Always. */ int machinemode(mode_t* restrict mode, mode_t* restrict mask, const char* restrict str) { diff --git a/src/slibc-human/unescape.c b/src/slibc-human/unescape.c index 90bf61c..da08b9a 100644 --- a/src/slibc-human/unescape.c +++ b/src/slibc-human/unescape.c @@ -48,6 +48,8 @@ * @throws 0 `str` is `NULL`. * @throws EINVAL If `mode` is invalid. * @throws EINVAL If `str` is invalid and `mode & UNESCAPE_EINVAL`. + * + * @since Always. */ char* unescape(char* str, enum unescape_mode mode) { diff --git a/src/slibc-print.c b/src/slibc-print.c index f1ed817..1a26a15 100644 --- a/src/slibc-print.c +++ b/src/slibc-print.c @@ -45,6 +45,8 @@ * * @throws Any error thrown by `write_function` or `extension_function`. * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int generic_printf(generic_printf_write_func_t write_function, generic_printf_ext_func_t extension_function, size_t maximum_length, int limited_length, size_t* restrict actual_length, int terminate, @@ -86,6 +88,8 @@ int generic_printf(generic_printf_write_func_t write_function, generic_printf_ex * * @throws Any error thrown by `write_function` or `extension_function`. * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int vgeneric_printf(generic_printf_write_func_t write_function, generic_printf_ext_func_t extension_function, size_t maximum_length, int limited_length, size_t* restrict actual_length, int terminate, @@ -131,6 +135,8 @@ int vgeneric_printf(generic_printf_write_func_t write_function, generic_printf_e * * @throws Any error thrown by `write_function` or `extension_function`. * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int generic_wprintf(generic_wprintf_write_func_t write_function, generic_wprintf_ext_func_t extension_function, size_t maximum_length, int limited_length, size_t* restrict actual_length, int terminate, @@ -173,6 +179,8 @@ int generic_wprintf(generic_wprintf_write_func_t write_function, generic_wprintf * * @throws Any error thrown by `write_function` or `extension_function`. * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int vgeneric_wprintf(generic_wprintf_write_func_t write_function, generic_wprintf_ext_func_t extension_function, size_t maximum_length, int limited_length, size_t* restrict actual_length, int terminate, diff --git a/src/stdio/printf.c b/src/stdio/printf.c index fa5dce9..4c5bae9 100644 --- a/src/stdio/printf.c +++ b/src/stdio/printf.c @@ -184,7 +184,7 @@ static int wwrite_fd(const wchar_t* text, size_t length, int* fdp) /** - * Write a string segment to a file. + * Write a string segment to a socket with `send`. * * @param text The text to write, not NUL terminated. * @param length The length of `text`. @@ -204,7 +204,7 @@ static int send_fd(const char* text, size_t length, int* input) /** - * Write a string segment to a file. + * Write a string segment to a socket with `send`. * * @param text The text to write, not NUL terminated. * @param length The length of `text`. @@ -361,6 +361,8 @@ static int wwrite_buffer(const wchar_t* text, size_t length, struct buffer* buff * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int printf(const char* restrict format, ...) { @@ -387,6 +389,8 @@ int printf(const char* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int fprintf(FILE* restrict stream, const char* restrict format, ...) { @@ -414,6 +418,8 @@ int fprintf(FILE* restrict stream, const char* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite_unlocked`. + * + * @since Always. */ int fprintf_unlocked(FILE* restrict stream, const char* restrict format, ...) { @@ -441,6 +447,8 @@ int fprintf_unlocked(FILE* restrict stream, const char* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int dprintf(int fd, const char* restrict format, ...) { @@ -471,6 +479,8 @@ int dprintf(int fd, const char* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int sockprintf(int fd, int flags, const char* format restrict, ...) { @@ -498,6 +508,8 @@ int sockprintf(int fd, int flags, const char* format restrict, ...) * use "%zn" to find the actual length. * * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int sprintf(char* restrict buffer, const char* restrict format, ...) { @@ -525,6 +537,8 @@ int sprintf(char* restrict buffer, const char* restrict format, ...) * actual length. * * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int snprintf(char* restrict buffer, size_t size, const char* restrict format, ...) { @@ -555,6 +569,8 @@ int snprintf(char* restrict buffer, size_t size, const char* restrict format, .. * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int asprintf(char** restrict buffer, const char* restrict format, ...) { @@ -602,6 +618,8 @@ int asprintf(char** restrict buffer, const char* restrict format, ...) * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int bprintf(char** restrict buffer, size_t* restrict size, size_t offset, int secure, const char* restrict format, ...) @@ -627,6 +645,8 @@ int bprintf(char** restrict buffer, size_t* restrict size, size_t offset, * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int vprintf(const char* restrict format, va_list args) { @@ -652,6 +672,8 @@ int vprintf(const char* restrict format, va_list args) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int vfprintf(FILE* restrict stream, const char* restrict format, va_list args) { @@ -684,6 +706,8 @@ int vfprintf(FILE* restrict stream, const char* restrict format, va_list args) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite_unlocked`. + * + * @since Always. */ int vfprintf_unlocked(FILE* restrict stream, const char* restrict format, va_list args) { @@ -709,6 +733,8 @@ int vfprintf_unlocked(FILE* restrict stream, const char* restrict format, va_lis * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int vdprintf(int fd, const char* restrict format, va_list args) { @@ -738,6 +764,8 @@ int vdprintf(int fd, const char* restrict format, va_list args) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int vsockprintf(int fd, int flags, const char* restrict format, va_list args) { @@ -763,6 +791,8 @@ int vsockprintf(int fd, int flags, const char* restrict format, va_list args) * use "%zn" to find the actual length. * * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int vsprintf(char* restrict buffer, const char* restrict format, va_list args) { @@ -791,6 +821,8 @@ int vsprintf(char* restrict buffer, const char* restrict format, va_list args) * actual length. * * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int vsnprintf(char* restrict buffer, size_t size, const char* restrict format, va_list args) { @@ -821,6 +853,8 @@ int vsnprintf(char* restrict buffer, size_t size, const char* restrict format, v * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int vasprintf(char** restrict buffer, const char* restrict format, va_list args) { @@ -871,6 +905,8 @@ int vasprintf(char** restrict buffer, const char* restrict format, va_list args) * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int vbprintf(char** restrict buffer, size_t* restrict size, size_t offset, int secure, const char* restrict format, va_list args) @@ -904,6 +940,8 @@ int vbprintf(char** restrict buffer, size_t* restrict size, size_t offset, * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int wprintf(const wchar_t* restrict format, ...) { @@ -929,6 +967,8 @@ int wprintf(const wchar_t* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int fwprintf(FILE* restrict stream, const wchar_t* restrict format, ...) { @@ -956,6 +996,8 @@ int fwprintf(FILE* restrict stream, const wchar_t* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite_unlocked`. + * + * @since Always. */ int fwprintf_unlocked(FILE* restrict stream, const wchar_t* restrict format, ...) { @@ -983,6 +1025,8 @@ int fwprintf_unlocked(FILE* restrict stream, const wchar_t* restrict format, ... * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int dwprintf(int fd, const wchar_t* restrict format, ...) { @@ -1012,6 +1056,8 @@ int dwprintf(int fd, const wchar_t* restrict format, ...) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int sockwprintf(int fd, int flags, const wchar_t* restrict format, ...) { @@ -1039,6 +1085,8 @@ int sockwprintf(int fd, int flags, const wchar_t* restrict format, ...) * actual length. * * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int swprintf(wchar_t* restrict buffer, size_t size, const wchar_t* restrict format, ...) { @@ -1069,6 +1117,8 @@ int swprintf(wchar_t* restrict buffer, size_t size, const wchar_t* restrict form * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int aswprintf(wchar_t** restrict buffer, const wchar_t* restrict format, ...) { @@ -1117,6 +1167,8 @@ int aswprintf(wchar_t** restrict buffer, const wchar_t* restrict format, ...) * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int bwprintf(wchar_t** restrict buffer, size_t* restrict size, size_t offset, int secure, const wchar_t* restrict format, ...) @@ -1142,6 +1194,8 @@ int bwprintf(wchar_t** restrict buffer, size_t* restrict size, size_t offset, * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int vwprintf(const wchar_t* restrict format, va_list args) { @@ -1167,6 +1221,8 @@ int vwprintf(const wchar_t* restrict format, va_list args) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite`. + * + * @since Always. */ int vfwprintf(FILE* restrict stream, const wchar_t* restrict format, va_list args) { @@ -1199,6 +1255,8 @@ int vfwprintf(FILE* restrict stream, const wchar_t* restrict format, va_list arg * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `fwrite_unlocked`. + * + * @since Always. */ int vfwprintf_unlocked(FILE* restrict stream, const wchar_t* restrict format, va_list args) { @@ -1226,6 +1284,8 @@ int vfwprintf_unlocked(FILE* restrict stream, const wchar_t* restrict format, va * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int vdwprintf(int fd, const wchar_t* restrict format, va_list args) { @@ -1255,6 +1315,8 @@ int vdwprintf(int fd, const wchar_t* restrict format, va_list args) * * @throws EINVAL `format` contained unsupported formatting codes. * @throws Any error specified for `write`. + * + * @since Always. */ int vsockwprintf(int fd, int flags, const wchar_t* restrict format, va_list args) { @@ -1283,6 +1345,8 @@ int vsockwprintf(int fd, int flags, const wchar_t* restrict format, va_list args * actual length. * * @throws EINVAL `format` contained unsupported formatting codes. + * + * @since Always. */ int vswprintf(wchar_t* restrict buffer, size_t size, const wchar_t* restrict format, va_list args) { @@ -1314,6 +1378,8 @@ int vswprintf(wchar_t* restrict buffer, size_t size, const wchar_t* restrict for * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int vaswprintf(wchar_t** restrict buffer, const wchar_t* restrict format, va_list args) { @@ -1365,6 +1431,8 @@ int vaswprintf(wchar_t** restrict buffer, const wchar_t* restrict format, va_lis * @throws EINVAL `format` contained unsupported formatting codes. * @throws ENOMEM The process cannot allocation the * sufficient amount of memory. + * + * @since Always. */ int vbwprintf(wchar_t** restrict buffer, size_t* restrict size, size_t offset, int secure, const wchar_t* restrict format, va_list args) diff --git a/src/stdio/scanf.c b/src/stdio/scanf.c index 9a88ec4..f5147dd 100644 --- a/src/stdio/scanf.c +++ b/src/stdio/scanf.c @@ -27,6 +27,8 @@ # pragma GCC diagnostic ignored "-Wcast-qual" # pragma GCC diagnostic ignored "-Wdiscarded-qualifiers" +/* TODO [v]sock[w]scanf (can use MSG_PEEK) */ +/* TODO doc: performance issue on [v]d[w]scanf */ @@ -80,6 +82,8 @@ extern int wread_fd(void); * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int scanf(const char* restrict format, ...) { @@ -100,6 +104,8 @@ int scanf(const char* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int fscanf(FILE* restrict stream, const char* restrict format, ...) { @@ -120,6 +126,8 @@ int fscanf(FILE* restrict stream, const char* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int sscanf(const char* restrict input, const char* restrict format, ...) { @@ -141,6 +149,8 @@ int sscanf(const char* restrict input, const char* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int fscanf_unlocked(FILE* restrict stream, const char* restrict format, ...) { @@ -165,6 +175,8 @@ int fscanf_unlocked(FILE* restrict stream, const char* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int snscanf(const char* restrict input, size_t length, const char* restrict format, ...) { @@ -188,6 +200,8 @@ int snscanf(const char* restrict input, size_t length, const char* restrict form * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int dscanf(int fd, const char* restrict format, ...) { @@ -206,6 +220,8 @@ int dscanf(int fd, const char* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vscanf(const char* restrict format, va_list args) { @@ -225,6 +241,8 @@ int vscanf(const char* restrict format, va_list args) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vfscanf(FILE* restrict stream, const char* restrict format, va_list args) { @@ -249,6 +267,8 @@ int vfscanf(FILE* restrict stream, const char* restrict format, va_list args) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vsscanf(const char* restrict input, const char* restrict format, va_list args) { @@ -270,6 +290,8 @@ int vsscanf(const char* restrict input, const char* restrict format, va_list arg * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vfscanf_unlocked(FILE* restrict stream, const char* restrict format, va_list args) { @@ -292,6 +314,8 @@ int vfscanf_unlocked(FILE* restrict stream, const char* restrict format, va_list * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vsnscanf(const char* restrict input, size_t length, const char* restrict format, va_list args) { @@ -313,6 +337,8 @@ int vsnscanf(const char* restrict input, size_t length, const char* restrict for * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vdscanf(int fd, const char* restrict format, va_list args) { @@ -331,6 +357,8 @@ int vdscanf(int fd, const char* restrict format, va_list args) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int wscanf(const wchar_t* restrict format, ...) { @@ -350,6 +378,8 @@ int wscanf(const wchar_t* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int fwscanf(FILE* restrict stream, const wchar_t* restrict format, ...) { @@ -369,6 +399,8 @@ int fwscanf(FILE* restrict stream, const wchar_t* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int swscanf(const wchar_t* restrict input, const wchar_t* restrict format, ...) { @@ -390,6 +422,8 @@ int swscanf(const wchar_t* restrict input, const wchar_t* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int fwscanf_unlocked(FILE* restrict stream, const wchar_t* restrict format, ...) { @@ -412,6 +446,8 @@ int fwscanf_unlocked(FILE* restrict stream, const wchar_t* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int snwscanf(const wchar_t* restrict input, size_t length, const wchar_t* restrict format, ...) { @@ -433,6 +469,8 @@ int snwscanf(const wchar_t* restrict input, size_t length, const wchar_t* restri * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int dwscanf(int fd, const wchar_t* restrict format, ...) { @@ -451,6 +489,8 @@ int dwscanf(int fd, const wchar_t* restrict format, ...) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vwscanf(const wchar_t* restrict format, va_list args) { @@ -470,6 +510,8 @@ int vwscanf(const wchar_t* restrict format, va_list args) * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vfwscanf(FILE* restrict stream, const wchar_t* restrict format, va_list args) { @@ -494,6 +536,8 @@ int vfwscanf(FILE* restrict stream, const wchar_t* restrict format, va_list args * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vswscanf(const wchar_t* restrict input, const wchar_t* restrict format, va_list args) { @@ -515,6 +559,8 @@ int vswscanf(const wchar_t* restrict input, const wchar_t* restrict format, va_l * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vfwscanf_unlocked(FILE* restrict stream, const wchar_t* restrict format, va_list args) { @@ -537,6 +583,8 @@ int vfwscanf_unlocked(FILE* restrict stream, const wchar_t* restrict format, va_ * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vsnwscanf(const wchar_t* restrict input, size_t length, const wchar_t* restrict format, va_list args) { @@ -558,6 +606,8 @@ int vsnwscanf(const wchar_t* restrict input, size_t length, const wchar_t* restr * if the end of the input is reached before the * first argument is successfully converted, or * on error. + * + * @since Always. */ int vdwscanf(int fd, const wchar_t* restrict format, va_list args) { @@ -568,6 +618,8 @@ int vdwscanf(int fd, const wchar_t* restrict format, va_list args) /** * This function is identical to `scanf`. + * + * @since Always. */ int __isoc99_scanf(const char* restrict format, ...) { @@ -576,6 +628,8 @@ int __isoc99_scanf(const char* restrict format, ...) /** * This function is identical to `fscanf`. + * + * @since Always. */ int __isoc99_fscanf(FILE* restrict stream, const char* restrict format, ...) { @@ -584,6 +638,8 @@ int __isoc99_fscanf(FILE* restrict stream, const char* restrict format, ...) /** * This function is identical to `sscanf`. + * + * @since Always. */ int __isoc99_sscanf(const char* restrict input, const char* restrict format, ...) { @@ -592,6 +648,8 @@ int __isoc99_sscanf(const char* restrict input, const char* restrict format, ... /** * This function is identical to `vscanf`. + * + * @since Always. */ int __isoc99_vscanf(const char* restrict format, va_list args) { @@ -600,6 +658,8 @@ int __isoc99_vscanf(const char* restrict format, va_list args) /** * This function is identical to `vfscanf`. + * + * @since Always. */ int __isoc99_vfscanf(FILE* restrict stream, const char* restrict format, va_list args) { @@ -608,6 +668,8 @@ int __isoc99_vfscanf(FILE* restrict stream, const char* restrict format, va_list /** * This function is identical to `vsscanf`. + * + * @since Always. */ int __isoc99_vsscanf(const char* restrict input, const char* restrict format, va_list args) { @@ -616,6 +678,8 @@ int __isoc99_vsscanf(const char* restrict input, const char* restrict format, va /** * This function is identical to `wscanf`. + * + * @since Always. */ int __isoc99_wscanf(const wchar_t* restrict format, ...) { @@ -624,6 +688,8 @@ int __isoc99_wscanf(const wchar_t* restrict format, ...) /** * This function is identical to `fwscanf`. + * + * @since Always. */ int __isoc99_fwscanf(FILE* restrict stream, const wchar_t* restrict format, ...) { @@ -632,6 +698,8 @@ int __isoc99_fwscanf(FILE* restrict stream, const wchar_t* restrict format, ...) /** * This function is identical to `swscanf`. + * + * @since Always. */ int __isoc99_swscanf(const wchar_t* restrict input, const wchar_t* restrict format, ...) { @@ -640,6 +708,8 @@ int __isoc99_swscanf(const wchar_t* restrict input, const wchar_t* restrict form /** * This function is identical to `vwscanf`. + * + * @since Always. */ int __isoc99_vwscanf(const wchar_t* restrict format, va_list args) { @@ -648,6 +718,8 @@ int __isoc99_vwscanf(const wchar_t* restrict format, va_list args) /** * This function is identical to `vfwscanf`. + * + * @since Always. */ int __isoc99_vfwscanf(FILE* restrict stream, const wchar_t* restrict format, va_list args) { @@ -656,6 +728,8 @@ int __isoc99_vfwscanf(FILE* restrict stream, const wchar_t* restrict format, va_ /** * This function is identical to `vswscanf`. + * + * @since Always. */ int __isoc99_vswscanf(const wchar_t* restrict input, const wchar_t* restrict format, va_list args) { diff --git a/src/stdlib/abs/abs.c b/src/stdlib/abs/abs.c index 9bc3bd4..ce2c81c 100644 --- a/src/stdlib/abs/abs.c +++ b/src/stdlib/abs/abs.c @@ -29,6 +29,8 @@ * * @param value The integer. * @return The absolute value of the integer. + * + * @since Always. */ int (abs)(int value) { diff --git a/src/stdlib/abs/labs.c b/src/stdlib/abs/labs.c index 20d0ac6..bf20bb8 100644 --- a/src/stdlib/abs/labs.c +++ b/src/stdlib/abs/labs.c @@ -29,6 +29,8 @@ * * @param value The integer. * @return The absolute value of the integer. + * + * @since Always. */ long int (labs)(long int value) { diff --git a/src/stdlib/abs/llabs.c b/src/stdlib/abs/llabs.c index 71e5a1b..8779d82 100644 --- a/src/stdlib/abs/llabs.c +++ b/src/stdlib/abs/llabs.c @@ -29,6 +29,8 @@ * * @param value The integer. * @return The absolute value of the integer. + * + * @since Always. */ long long int (llabs)(long long int value) { diff --git a/src/stdlib/abspath.c b/src/stdlib/abspath.c index a0f0871..83daa1b 100644 --- a/src/stdlib/abspath.c +++ b/src/stdlib/abspath.c @@ -36,6 +36,8 @@ * if `file` does. (Or if `ref` does but file is empty.) * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ char* abspath(const char* file, const char* ref) /* XXX may also fail as get_current_dir_name */ { diff --git a/src/stdlib/atof.c b/src/stdlib/atof.c index a4546b1..087912b 100644 --- a/src/stdlib/atof.c +++ b/src/stdlib/atof.c @@ -31,6 +31,8 @@ * * @param string The string to convert. * @return The number encoded by the string. + * + * @since Always. */ double atof(const char* string) { diff --git a/src/stdlib/atoi.c b/src/stdlib/atoi.c index 386c80d..6db57c5 100644 --- a/src/stdlib/atoi.c +++ b/src/stdlib/atoi.c @@ -32,6 +32,8 @@ * * @param string The string to convert. * @return The integer encoded by the string. + * + * @since Always. */ int atoi(const char* string) { diff --git a/src/stdlib/atol.c b/src/stdlib/atol.c index b4170e1..d0706a4 100644 --- a/src/stdlib/atol.c +++ b/src/stdlib/atol.c @@ -32,6 +32,8 @@ * * @param string The string to convert. * @return The integer encoded by the string. + * + * @since Always. */ long int atol(const char* string) { diff --git a/src/stdlib/atoll.c b/src/stdlib/atoll.c index ad26449..4e16bed 100644 --- a/src/stdlib/atoll.c +++ b/src/stdlib/atoll.c @@ -32,6 +32,8 @@ * * @param string The string to convert. * @return The integer encoded by the string. + * + * @since Always. */ long long int atoll(const char* string) { diff --git a/src/stdlib/atoq.c b/src/stdlib/atoq.c index 57d2c0a..c929661 100644 --- a/src/stdlib/atoq.c +++ b/src/stdlib/atoq.c @@ -23,6 +23,8 @@ * This function is identical to `atoll`. * * This is a Linux libc extension. + * + * @since Always. */ long long int atoq(const char* string) { diff --git a/src/stdlib/div/div.c b/src/stdlib/div/div.c index 3c071c5..1c5aa85 100644 --- a/src/stdlib/div/div.c +++ b/src/stdlib/div/div.c @@ -31,6 +31,8 @@ * the process will be killed by SIGFPE. * @return The quotient in `.quot`, and * the remainder in `.rem`. + * + * @since Always. */ div_t div(int numerator, int denominator) { diff --git a/src/stdlib/div/ldiv.c b/src/stdlib/div/ldiv.c index 40028fa..65e139d 100644 --- a/src/stdlib/div/ldiv.c +++ b/src/stdlib/div/ldiv.c @@ -31,6 +31,8 @@ * the process will be killed by SIGFPE. * @return The quotient in `.quot`, and * the remainder in `.rem`. + * + * @since Always. */ ldiv_t ldiv(long numerator, long denominator) { diff --git a/src/stdlib/div/lldiv.c b/src/stdlib/div/lldiv.c index 01ddd78..764cb9b 100644 --- a/src/stdlib/div/lldiv.c +++ b/src/stdlib/div/lldiv.c @@ -31,6 +31,8 @@ * the process will be killed by SIGFPE. * @return The quotient in `.quot`, and * the remainder in `.rem`. + * + * @since Always. */ lldiv_t lldiv(long long numerator, long long denominator) { diff --git a/src/stdlib/relpath.c b/src/stdlib/relpath.c index e3d7e24..f710523 100644 --- a/src/stdlib/relpath.c +++ b/src/stdlib/relpath.c @@ -37,6 +37,8 @@ * point to `file`. * * @throws ENOMEM The process cannot allocate more memory. + * + * @since Always. */ char* relpath(const char* file, const char* ref) /* XXX may also fail as get_current_dir_name */ { diff --git a/src/string/basename_gnu.c b/src/string/basename_gnu.c index 6fb474a..c25fb1e 100644 --- a/src/string/basename_gnu.c +++ b/src/string/basename_gnu.c @@ -34,6 +34,8 @@ * of `filename` or, if `filename` is `NULL` * or is empty, a statically allocationed string, * so it must not freed or edited. + * + * @since Always. */ char* __gnu_basename(const char* filename) { diff --git a/src/string/mem/memcasecmp.c b/src/string/mem/memcasecmp.c index d8ea014..816c954 100644 --- a/src/string/mem/memcasecmp.c +++ b/src/string/mem/memcasecmp.c @@ -31,6 +31,8 @@ * @param size The size of the segments. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int memcasecmp(const void* a, const void* b, size_t size) { diff --git a/src/string/mem/memcasemem.c b/src/string/mem/memcasemem.c index aad5d68..b15daea 100644 --- a/src/string/mem/memcasemem.c +++ b/src/string/mem/memcasemem.c @@ -38,6 +38,8 @@ * @param needle_length The length of `needle`. * @return Pointer to the first occurrence of * the substring, `NULL` if not found. + * + * @since Always. */ void* (memcasemem)(const void* __haystack, size_t haystack_length, const void* __needle, size_t needle_length) diff --git a/src/string/mem/memccpy.c b/src/string/mem/memccpy.c index 01b4a4b..f5c669e 100644 --- a/src/string/mem/memccpy.c +++ b/src/string/mem/memccpy.c @@ -32,6 +32,8 @@ * that is, the address of `whither` plus the * number of copied characters; the address of * one character passed the last written character. + * + * @since Always. */ void* (memccpy)(void* restrict whither, const void* restrict whence, int c, size_t size) { diff --git a/src/string/mem/memchr.c b/src/string/mem/memchr.c index 380fa0f..06c82a8 100644 --- a/src/string/mem/memchr.c +++ b/src/string/mem/memchr.c @@ -30,6 +30,8 @@ * @param size The size of the memory segment. * @return Pointer to the first occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ void* (memchr)(const void* segment, int c, size_t size) { diff --git a/src/string/mem/memcmove.c b/src/string/mem/memcmove.c index ad10606..c1cf8ae 100644 --- a/src/string/mem/memcmove.c +++ b/src/string/mem/memcmove.c @@ -34,6 +34,8 @@ * that is, the address of `whither` plus the * number of copied characters; the address of * one character passed the last written character. + * + * @since Always. */ void* (memcmove)(void* whither, const void* whence, int c, size_t size) { diff --git a/src/string/mem/memcmp.c b/src/string/mem/memcmp.c index 112cdd1..1de506d 100644 --- a/src/string/mem/memcmp.c +++ b/src/string/mem/memcmp.c @@ -27,6 +27,8 @@ * @param size The size of the segments. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int memcmp(const void* a, const void* b, size_t size) { diff --git a/src/string/mem/memcpy.c b/src/string/mem/memcpy.c index fcda29d..ccf716b 100644 --- a/src/string/mem/memcpy.c +++ b/src/string/mem/memcpy.c @@ -26,6 +26,8 @@ * @param whence The source memory segment. * @param size The number of bytes to copy. * @return `whither` is returned. + * + * @since Always. */ void* memcpy(void* restrict whither, const void* restrict whence, size_t size) { diff --git a/src/string/mem/memdup.c b/src/string/mem/memdup.c index 3b301dc..3e3be99 100644 --- a/src/string/mem/memdup.c +++ b/src/string/mem/memdup.c @@ -31,6 +31,8 @@ * and `errno` is set to indicate the error. * * @throws ENOMEM The process could not allocate sufficient amount of memory. + * + * @since Always. */ void* memdup(const void* segment, size_t size) { diff --git a/src/string/mem/memmem.c b/src/string/mem/memmem.c index 62739d4..71d1f4d 100644 --- a/src/string/mem/memmem.c +++ b/src/string/mem/memmem.c @@ -37,6 +37,8 @@ * @param needle_length The length of `needle`. * @return Pointer to the first occurrence of * the substring, `NULL` if not found. + * + * @since Always. */ void* (memmem)(const void* __haystack, size_t haystack_length, const void* __needle, size_t needle_length) diff --git a/src/string/mem/memmove.c b/src/string/mem/memmove.c index 41871c6..00ee9c1 100644 --- a/src/string/mem/memmove.c +++ b/src/string/mem/memmove.c @@ -26,6 +26,8 @@ * @param whence The source memory segment. * @param size The number of bytes to copy. * @return `whither` is returned. + * + * @since Always. */ void* memmove(void* whither, const void* whence, size_t size) { diff --git a/src/string/mem/mempcpy.c b/src/string/mem/mempcpy.c index 2072dc3..97b81f1 100644 --- a/src/string/mem/mempcpy.c +++ b/src/string/mem/mempcpy.c @@ -28,6 +28,8 @@ * @param whence The source memory segment. * @param size The number of bytes to copy. * @return `whither + size` is returned. + * + * @since Always. */ void* mempcpy(void* restrict whither, const void* restrict whence, size_t size) { diff --git a/src/string/mem/mempmove.c b/src/string/mem/mempmove.c index f837032..415e38b 100644 --- a/src/string/mem/mempmove.c +++ b/src/string/mem/mempmove.c @@ -29,6 +29,8 @@ * @param whence The source memory segment. * @param size The number of bytes to copy. * @return `whither + size` is returned. + * + * @since Always. */ void* mempmove(void* whither, const void* whence, size_t size) { diff --git a/src/string/mem/memrchr.c b/src/string/mem/memrchr.c index 7325049..2781a71 100644 --- a/src/string/mem/memrchr.c +++ b/src/string/mem/memrchr.c @@ -34,6 +34,8 @@ * @param size The size of the memory segment. * @return Pointer to the last occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ void* (memrchr)(const void* segment, int c, size_t size) { diff --git a/src/string/mem/memset.c b/src/string/mem/memset.c index df36052..047620b 100644 --- a/src/string/mem/memset.c +++ b/src/string/mem/memset.c @@ -26,6 +26,8 @@ * @param c The character (8 bits wide.) * @param size The size of the memory segment. * @return `segment` is returned. + * + * @since Always. */ void* memset(void* segment, int c, size_t size) { diff --git a/src/string/mem/rawmemchr.c b/src/string/mem/rawmemchr.c index 8f5c03e..afaae48 100644 --- a/src/string/mem/rawmemchr.c +++ b/src/string/mem/rawmemchr.c @@ -31,6 +31,8 @@ * @param segment The memory segment to search. * @param c The sought after character. * @return Pointer to the first occurrence of `c`. + * + * @since Always. */ void* (rawmemchr)(const void* segment, int c) { diff --git a/src/string/memfrob.c b/src/string/memfrob.c index 7ec9abd..77c2e40 100644 --- a/src/string/memfrob.c +++ b/src/string/memfrob.c @@ -28,6 +28,8 @@ * @param segment The memory segment. * @param size The size of the memory segment. * @return `segment` is returned + * + * @since Always. */ char* memfrob(char* segment, size_t size) { diff --git a/src/string/new.c b/src/string/new.c index 28d2b22..56b4e92 100644 --- a/src/string/new.c +++ b/src/string/new.c @@ -28,6 +28,8 @@ * @param str The string. * @param stop The additional termination-byte. * @return The number of bytes before, the first termination-byte. + * + * @since Always. */ size_t strclen(const char* string, int stop) { @@ -45,6 +47,8 @@ size_t strclen(const char* string, int stop) * @param maxlen The number of bytes to inspect, at most. * @return The number of bytes before, the first termination-byte. * `maxlen` if no termination-byte was found. + * + * @since Always. */ size_t strcnlen(const char* string, int stop, size_t maxlen) { @@ -61,6 +65,8 @@ size_t strcnlen(const char* string, int stop, size_t maxlen) * @param str The string. * @param stop The additional termination-mark. * @return The number of bytes before, the first termination-mark. + * + * @since Always. */ size_t strstrlen(const char* string, const char* stop) { @@ -79,6 +85,8 @@ size_t strstrlen(const char* string, const char* stop) * @param maxlen The number of bytes to inspect, at most. * @return The number of bytes before, the first termination-mark. * `maxlen` if no termination-byte was found. + * + * @since Always. */ size_t strstrnlen(const char* string, const char* stop, size_t maxlen) { @@ -99,6 +107,8 @@ size_t strstrnlen(const char* string, const char* stop, size_t maxlen) * @param maxlen The number of bytes to inspect, at most. * @return Pointer to the first occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ char* (strnchr)(const char* string, int c, size_t maxlen) { @@ -124,6 +134,8 @@ char* (strnchr)(const char* string, int c, size_t maxlen) * part of the sring) if non were found. If the * whole string was inspected, the returned * pointer will point to a NUL byte. + * + * @since Always. */ char* (strnchrnul)(const char* string, int c, size_t maxlen) { diff --git a/src/string/str/rawstrcasestr.c b/src/string/str/rawstrcasestr.c index 7e4cf9b..bae8c38 100644 --- a/src/string/str/rawstrcasestr.c +++ b/src/string/str/rawstrcasestr.c @@ -30,6 +30,8 @@ * @param haystack The string to search. * @param needle The sought after substring. * @return Pointer to the first occurrence of the substring. + * + * @since Always. */ char* (rawstrcasestr)(const char* haystack, const char* needle) { diff --git a/src/string/str/rawstrstr.c b/src/string/str/rawstrstr.c index 9c3f186..8349210 100644 --- a/src/string/str/rawstrstr.c +++ b/src/string/str/rawstrstr.c @@ -29,6 +29,8 @@ * @param haystack The string to search. * @param needle The sought after substring. * @return Pointer to the first occurrence of the substring. + * + * @since Always. */ char* (rawstrstr)(const char* haystack, const char* needle) { diff --git a/src/string/str/stpcpy.c b/src/string/str/stpcpy.c index a0d5f79..c643d77 100644 --- a/src/string/str/stpcpy.c +++ b/src/string/str/stpcpy.c @@ -26,6 +26,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither + strlen(whence)` is returned. + * + * @since Always. */ char* stpcpy(char* restrict whither, const char* restrict whence) { diff --git a/src/string/str/stpmove.c b/src/string/str/stpmove.c index 8818c30..56ddd24 100644 --- a/src/string/str/stpmove.c +++ b/src/string/str/stpmove.c @@ -28,6 +28,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither + strlen(whence)` is returned. + * + * @since Always. */ char* stpmove(char* whither, const char* whence) { diff --git a/src/string/str/strcasecmp.c b/src/string/str/strcasecmp.c index c4b9175..f2d6e83 100644 --- a/src/string/str/strcasecmp.c +++ b/src/string/str/strcasecmp.c @@ -31,6 +31,8 @@ * @param b A positive value is returned if this is the lesser. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int strcasecmp(const char* a, const char* b) { diff --git a/src/string/str/strcaseends.c b/src/string/str/strcaseends.c index 9155ea8..b9a1756 100644 --- a/src/string/str/strcaseends.c +++ b/src/string/str/strcaseends.c @@ -29,6 +29,8 @@ * @param desired The desired ending of the string. * @return The `string`, where `desired` beings if * `string` ends with `desired`, `NULL` otherwise. + * + * @since Always. */ char* (strcaseends)(const char* string, const char* desired) { diff --git a/src/string/str/strcasestarts.c b/src/string/str/strcasestarts.c index f584da4..d17b936 100644 --- a/src/string/str/strcasestarts.c +++ b/src/string/str/strcasestarts.c @@ -29,6 +29,8 @@ * @param desired The desired beginning of the string. * @return `string` if `string` begins with * `desired`, `NULL` otherwise. + * + * @since Always. */ char* (strcasestarts)(const char* string, const char* desired) { diff --git a/src/string/str/strcasestr.c b/src/string/str/strcasestr.c index 6468750..0ac4368 100644 --- a/src/string/str/strcasestr.c +++ b/src/string/str/strcasestr.c @@ -27,6 +27,8 @@ * @param needle The sought after substring. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ char* (strcasestr)(const char* haystack, const char* needle) { diff --git a/src/string/str/strcat.c b/src/string/str/strcat.c index de5c63e..ec3cbe7 100644 --- a/src/string/str/strcat.c +++ b/src/string/str/strcat.c @@ -28,6 +28,8 @@ * @param whither The string to extend. * @param whence The string to append. * @return `whither` is returned. + * + * @since Always. */ char* strcat(char* restrict whither, const char* restrict whence) { diff --git a/src/string/str/strccpy.c b/src/string/str/strccpy.c index 2d1bcd8..14b179b 100644 --- a/src/string/str/strccpy.c +++ b/src/string/str/strccpy.c @@ -34,6 +34,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strccpy(char* restrict whither, const char* restrict whence, int c) { diff --git a/src/string/str/strchr.c b/src/string/str/strchr.c index 0ed53b4..8226726 100644 --- a/src/string/str/strchr.c +++ b/src/string/str/strchr.c @@ -34,6 +34,8 @@ * @param c The sought after character. * @return Pointer to the first occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ char* (strchr)(const char* string, int c) { diff --git a/src/string/str/strchrnul.c b/src/string/str/strchrnul.c index 50dedfe..72ae9bc 100644 --- a/src/string/str/strchrnul.c +++ b/src/string/str/strchrnul.c @@ -35,6 +35,8 @@ * @return Pointer to the first occurrence of `c`, * Pointer to the terminating NUL character * if none were found. + * + * @since Always. */ char* (strchrnul)(const char* string, int c) { diff --git a/src/string/str/strcmove.c b/src/string/str/strcmove.c index 8310b27..b2f877f 100644 --- a/src/string/str/strcmove.c +++ b/src/string/str/strcmove.c @@ -34,6 +34,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strcmove(char* whither, const char* whence, int c) { diff --git a/src/string/str/strcmp.c b/src/string/str/strcmp.c index 3099d71..cf9426d 100644 --- a/src/string/str/strcmp.c +++ b/src/string/str/strcmp.c @@ -26,6 +26,8 @@ * @param b A positive value is returned if this is the lesser. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int strcmp(const char* a, const char* b) { diff --git a/src/string/str/strcpy.c b/src/string/str/strcpy.c index 75d88e7..d0fcd76 100644 --- a/src/string/str/strcpy.c +++ b/src/string/str/strcpy.c @@ -26,6 +26,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither` is returned. + * + * @since Always. */ char* strcpy(char* restrict whither, const char* restrict whence) { diff --git a/src/string/str/strcspn.c b/src/string/str/strcspn.c index 35b3404..32cb530 100644 --- a/src/string/str/strcspn.c +++ b/src/string/str/strcspn.c @@ -27,6 +27,8 @@ * @param string The string. * @param stopset Bytes disallowed in the substring. * @return The length of the substring. + * + * @since Always. */ size_t strcspn(const char* string, const char* stopset) { diff --git a/src/string/str/strdup.c b/src/string/str/strdup.c index b7155d7..50ba069 100644 --- a/src/string/str/strdup.c +++ b/src/string/str/strdup.c @@ -28,6 +28,8 @@ * and `errno` is set to indicate the error. * * @throws ENOMEM The process could not allocate sufficient amount of memory. + * + * @since Always. */ char* strdup(const char* string) { diff --git a/src/string/str/strends.c b/src/string/str/strends.c index 957301c..43dd562 100644 --- a/src/string/str/strends.c +++ b/src/string/str/strends.c @@ -29,6 +29,8 @@ * @param desired The desired ending of the string. * @return The `string`, where `desired` beings if * `string` ends with `desired`, `NULL` otherwise. + * + * @since Always. */ char* (strends)(const char* string, const char* desired) { diff --git a/src/string/str/strlen.c b/src/string/str/strlen.c index 2092ddc..16b7977 100644 --- a/src/string/str/strlen.c +++ b/src/string/str/strlen.c @@ -25,6 +25,8 @@ * * @param str The string. * @return The number of bytes before the first NUL byte. + * + * @since Always. */ size_t strlen(const char* str) { diff --git a/src/string/str/strmove.c b/src/string/str/strmove.c index 4bd52f4..892b852 100644 --- a/src/string/str/strmove.c +++ b/src/string/str/strmove.c @@ -28,6 +28,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither` is returned. + * + * @since Always. */ char* strmove(char* whither, const char* whence) { diff --git a/src/string/str/strpbrk.c b/src/string/str/strpbrk.c index e479dae..4cfb9ed 100644 --- a/src/string/str/strpbrk.c +++ b/src/string/str/strpbrk.c @@ -30,6 +30,8 @@ * @return A pointer to the first occurrence in * `string` of a byte found in `stopset`. * `NULL` is returned if none is found. + * + * @since Always. */ char* (strpbrk)(const char* string, const char* stopset) { diff --git a/src/string/str/strrchr.c b/src/string/str/strrchr.c index 716a442..1933765 100644 --- a/src/string/str/strrchr.c +++ b/src/string/str/strrchr.c @@ -35,6 +35,8 @@ * @param c The sought after character. * @return Pointer to the last occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ char* (strrchr)(const char* string, int c) { diff --git a/src/string/str/strsep.c b/src/string/str/strsep.c index 9fa0cff..c51e47f 100644 --- a/src/string/str/strsep.c +++ b/src/string/str/strsep.c @@ -33,6 +33,8 @@ * `NULL` is returned the search as reached * the end of the string, and there therefore * are no more tokens. + * + * @since Always. */ char* strsep(char** restrict string, const char* restrict delimiters) { diff --git a/src/string/str/strset.c b/src/string/str/strset.c index c1eca65..ac1d551 100644 --- a/src/string/str/strset.c +++ b/src/string/str/strset.c @@ -28,6 +28,8 @@ * @param str The beginning of the memory segment. * @param c The character (8 bits wide.) * @return `str` is returned. + * + * @since Always. */ char* strset(char* str, int c) { diff --git a/src/string/str/strspn.c b/src/string/str/strspn.c index 1b2e034..8a648ff 100644 --- a/src/string/str/strspn.c +++ b/src/string/str/strspn.c @@ -27,6 +27,8 @@ * @param string The string. * @param skipset Bytes allowed in the substring. * @return The length of the substring. + * + * @since Always. */ size_t strspn(const char* string, const char* skipset) { diff --git a/src/string/str/strstarts.c b/src/string/str/strstarts.c index e132b68..e562f63 100644 --- a/src/string/str/strstarts.c +++ b/src/string/str/strstarts.c @@ -29,6 +29,8 @@ * @param desired The desired beginning of the string. * @return `string` if `string` begins with * `desired`, `NULL` otherwise. + * + * @since Always. */ char* (strstarts)(const char* string, const char* desired) { diff --git a/src/string/str/strstr.c b/src/string/str/strstr.c index dadbc73..9f88cb4 100644 --- a/src/string/str/strstr.c +++ b/src/string/str/strstr.c @@ -27,6 +27,8 @@ * @param needle The sought after substring. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ char* (strstr)(const char* haystack, const char* needle) { diff --git a/src/string/str/strstrcpy.c b/src/string/str/strstrcpy.c index 9dc9105..bd4c5a6 100644 --- a/src/string/str/strstrcpy.c +++ b/src/string/str/strstrcpy.c @@ -34,6 +34,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strstrcpy(char* restrict whither, const char* restrict whence, const char* restrict str) { diff --git a/src/string/str/strstrmove.c b/src/string/str/strstrmove.c index 19969cd..686b0bd 100644 --- a/src/string/str/strstrmove.c +++ b/src/string/str/strstrmove.c @@ -34,6 +34,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strstrmove(char* whither, const char* whence, const char* restrict str) { diff --git a/src/string/str/strtok.c b/src/string/str/strtok.c index b1b56b9..a856967 100644 --- a/src/string/str/strtok.c +++ b/src/string/str/strtok.c @@ -33,6 +33,8 @@ * `NULL` is returned the search as reached * the end of the string, and there therefore * are no more tokens. + * + * @since Always. */ char* strtok(char* restrict string, const char* restrict delimiters) { diff --git a/src/string/str/strtok_r.c b/src/string/str/strtok_r.c index 3005ac7..e29e11b 100644 --- a/src/string/str/strtok_r.c +++ b/src/string/str/strtok_r.c @@ -37,6 +37,8 @@ * `NULL` is returned the search as reached * the end of the string, and there therefore * are no more tokens. + * + * @since Always. */ char* strtok_r(char* restrict string, const char* restrict delimiters, char** restrict state) diff --git a/src/string/strerror/strerror.c b/src/string/strerror/strerror.c index 315e40d..75af8bd 100644 --- a/src/string/strerror/strerror.c +++ b/src/string/strerror/strerror.c @@ -36,6 +36,8 @@ * * @param errnum The error code. * @return A description of the error. + * + * @since Always. */ char* strerror(int errnum) { diff --git a/src/string/strerror/strerror_l.c b/src/string/strerror/strerror_l.c index 838040f..0493d9f 100644 --- a/src/string/strerror/strerror_l.c +++ b/src/string/strerror/strerror_l.c @@ -34,6 +34,8 @@ * @param locale The locale, must be a valid locale and not * `LC_GLOBAL_LOCALE`, lest the behaviour is undefined. * @return A description of the error. + * + * @since Always. */ char* strerror_l(int errnum, locale_t locale) { diff --git a/src/string/strerror/strerror_r_gnu.c b/src/string/strerror/strerror_r_gnu.c index 3e8bfd4..539866a 100644 --- a/src/string/strerror/strerror_r_gnu.c +++ b/src/string/strerror/strerror_r_gnu.c @@ -36,6 +36,8 @@ * is set to indicate the error. * * @throws ERANGE `buf` was too small to store the description. + * + * @since Always. */ char* __gnu_strerror_r(int errnum, char* buf, size_t buflen) { diff --git a/src/string/strerror/strerror_r_xsi.c b/src/string/strerror/strerror_r_xsi.c index 70c3bc8..028226e 100644 --- a/src/string/strerror/strerror_r_xsi.c +++ b/src/string/strerror/strerror_r_xsi.c @@ -35,6 +35,8 @@ * @return Zero on success, value for `errno` on error * * @throws ERANGE `buf` was too small to store the description. + * + * @since Always. */ int __xsi_strerror_r(int errnum, char* buf, size_t buflen) { diff --git a/src/string/strfry.c b/src/string/strfry.c index da6d0ac..ac8ef13 100644 --- a/src/string/strfry.c +++ b/src/string/strfry.c @@ -30,6 +30,8 @@ * * @param anagram An anagram of the output, will be modified. * @retrun The string, which will `== anagram`. + * + * @since Always. */ char* strfry(char* anagram) { diff --git a/src/string/strn/stpncpy.c b/src/string/strn/stpncpy.c index 4290dab..561adc3 100644 --- a/src/string/strn/stpncpy.c +++ b/src/string/strn/stpncpy.c @@ -35,6 +35,8 @@ * until this amount of bytes have been written. * @return `whither` plus the number of written bytes, * excluding NUL bytes, is returned. + * + * @since Always. */ char* stpncpy(char* restrict whither, const char* restrict whence, size_t maxlen) { diff --git a/src/string/strn/stpnmove.c b/src/string/strn/stpnmove.c index 917b753..e410b49 100644 --- a/src/string/strn/stpnmove.c +++ b/src/string/strn/stpnmove.c @@ -36,6 +36,8 @@ * until this amount of bytes have been written. * @return `whither` plus the number of written bytes, * excluding NUL bytes, is returned. + * + * @since Always. */ char* stpnmove(char* whither, const char* whence, size_t maxlen) { diff --git a/src/string/strn/strcncpy.c b/src/string/strn/strcncpy.c index 594e7df..fb244b1 100644 --- a/src/string/strn/strcncpy.c +++ b/src/string/strn/strcncpy.c @@ -41,6 +41,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strcncpy(char* restrict whither, const char* restrict whence, int c, size_t maxlen) { diff --git a/src/string/strn/strcnmove.c b/src/string/strn/strcnmove.c index 5fbdf19..f039959 100644 --- a/src/string/strn/strcnmove.c +++ b/src/string/strn/strcnmove.c @@ -41,6 +41,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strcnmove(char* whither, const char* whence, int c, size_t maxlen) { diff --git a/src/string/strn/strncasecmp.c b/src/string/strn/strncasecmp.c index da9a1ba..d5fa666 100644 --- a/src/string/strn/strncasecmp.c +++ b/src/string/strn/strncasecmp.c @@ -32,6 +32,8 @@ * @param length The maximum number of characters to compare. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int strncasecmp(const char* a, const char* b, size_t length) { diff --git a/src/string/strn/strncasestr.c b/src/string/strn/strncasestr.c index e95dc4b..c74d590 100644 --- a/src/string/strn/strncasestr.c +++ b/src/string/strn/strncasestr.c @@ -30,6 +30,8 @@ * @param maxlen The maximum number of character to search. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ char* (strncasestr)(const char* haystack, const char* needle, size_t maxlen) { diff --git a/src/string/strn/strncat.c b/src/string/strn/strncat.c index e7db0f2..1d6d35b 100644 --- a/src/string/strn/strncat.c +++ b/src/string/strn/strncat.c @@ -34,6 +34,8 @@ * shorter, `whither` will be filled with NUL bytes * until this amount of bytes have been written. * @return `whither` is returned. + * + * @since Always. */ char* strncat(char* restrict whither, const char* restrict whence, size_t maxlen) { diff --git a/src/string/strn/strncmp.c b/src/string/strn/strncmp.c index 2c078d8..08bf5c1 100644 --- a/src/string/strn/strncmp.c +++ b/src/string/strn/strncmp.c @@ -27,6 +27,8 @@ * @param length The maximum number of characters to compare. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int strncmp(const char* a, const char* b, size_t length) { diff --git a/src/string/strn/strncpy.c b/src/string/strn/strncpy.c index 3a1e66b..199ca9c 100644 --- a/src/string/strn/strncpy.c +++ b/src/string/strn/strncpy.c @@ -32,6 +32,8 @@ * shorter, `whither` will be filled with NUL bytes * until this amount of bytes have been written. * @return `whither` is returned. + * + * @since Always. */ char* strncpy(char* restrict whither, const char* restrict whence, size_t maxlen) { diff --git a/src/string/strn/strndup.c b/src/string/strn/strndup.c index ca3b3f0..51aa2bb 100644 --- a/src/string/strn/strndup.c +++ b/src/string/strn/strndup.c @@ -33,6 +33,8 @@ * and `errno` is set to indicate the error. * * @throws ENOMEM The process could not allocate sufficient amount of memory. + * + * @since Always. */ char* strndup(const char* string, size_t maxlen) { diff --git a/src/string/strn/strnlen.c b/src/string/strn/strnlen.c index 5473682..2d45e68 100644 --- a/src/string/strn/strnlen.c +++ b/src/string/strn/strnlen.c @@ -27,6 +27,8 @@ * @param maxlen The number of bytes to inspect, at most. * @return The number of bytes before, the first NUL byte. * `maxlen` if no NUL byte was found. + * + * @since Always. */ size_t strnlen(const char* str, size_t maxlen) { diff --git a/src/string/strn/strnmove.c b/src/string/strn/strnmove.c index 0d22c15..dc159db 100644 --- a/src/string/strn/strnmove.c +++ b/src/string/strn/strnmove.c @@ -34,6 +34,8 @@ * shorter, `whither` will be filled with NUL bytes * until this amount of bytes have been written. * @return `whither` is returned. + * + * @since Always. */ char* strnmove(char* whither, const char* whence, size_t maxlen) { diff --git a/src/string/strn/strnstr.c b/src/string/strn/strnstr.c index 8db61ac..e581116 100644 --- a/src/string/strn/strnstr.c +++ b/src/string/strn/strnstr.c @@ -31,6 +31,8 @@ * @param maxlen The maximum number of character to search. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ char* (strnstr)(const char* haystack, const char* needle, size_t maxlen) { diff --git a/src/string/strn/strstrncpy.c b/src/string/strn/strstrncpy.c index 43b58fe..822c4c6 100644 --- a/src/string/strn/strstrncpy.c +++ b/src/string/strn/strstrncpy.c @@ -41,6 +41,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strstrncpy(char* restrict whither, const char* restrict whence, const char* restrict str, size_t maxlen) diff --git a/src/string/strn/strstrnmove.c b/src/string/strn/strstrnmove.c index d1c63f9..aadb1a9 100644 --- a/src/string/strn/strstrnmove.c +++ b/src/string/strn/strstrnmove.c @@ -41,6 +41,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ char* strstrnmove(char* whither, const char* whence, const char* restrict str, size_t maxlen) { diff --git a/src/strings/bcmp.c b/src/strings/bcmp.c index 23e6126..73f98be 100644 --- a/src/strings/bcmp.c +++ b/src/strings/bcmp.c @@ -24,6 +24,8 @@ * This function is identical to `memcmp`. * * @etymology (B)uffer: (c)o(mp)are. + * + * @since Always. */ int bcmp(const void* a, const void* b, size_t size) { diff --git a/src/strings/bcopy.c b/src/strings/bcopy.c index 1abeb7c..fa44e87 100644 --- a/src/strings/bcopy.c +++ b/src/strings/bcopy.c @@ -28,6 +28,8 @@ * @param whence The source memory segment. * @param whither The destination memory segment. * @param size The number of bytes to copy. + * + * @since Always. */ void bcopy(const void* whence, void* whither, size_t size) { diff --git a/src/strings/bzero.c b/src/strings/bzero.c index e581b94..a85bbda 100644 --- a/src/strings/bzero.c +++ b/src/strings/bzero.c @@ -27,6 +27,8 @@ * * @param segment The memory segment to override. * @param size The size of the memory segment. + * + * @since Always. */ void bzero(void* segment, size_t size) { diff --git a/src/strings/explicit_bzero.c b/src/strings/explicit_bzero.c index 387c666..34e2cac 100644 --- a/src/strings/explicit_bzero.c +++ b/src/strings/explicit_bzero.c @@ -37,6 +37,8 @@ void* (*volatile __slibc_explicit_memset)(void*, int, size_t) = memset; * * @param segment The memory segment to override. * @param size The size of the memory segment. + * + * @since Always. */ void explicit_bzero(void* segment, size_t size) { diff --git a/src/strings/ffs.c b/src/strings/ffs.c index 46ad612..e51c0cf 100644 --- a/src/strings/ffs.c +++ b/src/strings/ffs.c @@ -26,6 +26,8 @@ * * @param i The integer. * @return The value of the least significant set bit, zero if none. + * + * @since Always. */ int ffs(int i) { diff --git a/src/strings/ffsl.c b/src/strings/ffsl.c index 3116723..a93387b 100644 --- a/src/strings/ffsl.c +++ b/src/strings/ffsl.c @@ -26,6 +26,8 @@ * * @param i The integer. * @return The value of the least significant set bit, zero if none. + * + * @since Always. */ int ffsl(long i) { diff --git a/src/strings/ffsll.c b/src/strings/ffsll.c index 13d4c14..c643b41 100644 --- a/src/strings/ffsll.c +++ b/src/strings/ffsll.c @@ -26,6 +26,8 @@ * * @param i The integer. * @return The value of the least significant set bit, zero if none. + * + * @since Always. */ int ffsll(long long i) { diff --git a/src/strings/index.c b/src/strings/index.c index 332811d..543fffe 100644 --- a/src/strings/index.c +++ b/src/strings/index.c @@ -26,6 +26,8 @@ * This is a deprecated BSD extension. * * @etymology (Index) of character. + * + * @since Always. */ char* (index)(const char* string, int c) { diff --git a/src/strings/rindex.c b/src/strings/rindex.c index 3e39a9e..b131367 100644 --- a/src/strings/rindex.c +++ b/src/strings/rindex.c @@ -26,6 +26,8 @@ * This is a deprecated BSD extension. * * @etymology (R)ight-most (index) of character. + * + * @since Always. */ char* (rindex)(const char* string, int c) { diff --git a/src/unistd/exec.c b/src/unistd/exec.c index 0b76259..c6e4fca 100644 --- a/src/unistd/exec.c +++ b/src/unistd/exec.c @@ -29,6 +29,8 @@ /** * The current environment variables. + * + * @since Always. */ extern char** environ; @@ -44,6 +46,8 @@ extern char** environ; * @param use_path Whether $PATH may be used. * * @throws Any error specified for execve(2). + * + * @since Always. */ static void vexec(const char* file, va_list argv, int fetch_envp, int use_path) { @@ -82,6 +86,8 @@ static void vexec(const char* file, va_list argv, int fetch_envp, int use_path) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execl(const char* path, ... /*, NULL */) { @@ -112,6 +118,8 @@ int execl(const char* path, ... /*, NULL */) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execlp(const char* file, ... /*, NULL */) { @@ -142,6 +150,8 @@ int execlp(const char* file, ... /*, NULL */) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execle(const char* path, ... /*, NULL, char* const envp[] */) { @@ -178,6 +188,8 @@ int execle(const char* path, ... /*, NULL, char* const envp[] */) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execlpe(const char* file, ... /*, NULL, char* const envp[] */) { @@ -208,6 +220,8 @@ int execlpe(const char* file, ... /*, NULL, char* const envp[] */) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execv(const char* path, char* const argv[]) { @@ -236,6 +250,8 @@ int execv(const char* path, char* const argv[]) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execvp(const char* file, char* const argv[]) { @@ -264,6 +280,8 @@ int execvp(const char* file, char* const argv[]) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execve(const char* path, char* const argv[], char* const envp[]) { @@ -300,6 +318,8 @@ int execve(const char* path, char* const argv[], char* const envp[]) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int execvpe(const char* file, char* const argv[], char* const envp[]) { diff --git a/src/unistd/execat.c b/src/unistd/execat.c index a7de5dd..68d9cfd 100644 --- a/src/unistd/execat.c +++ b/src/unistd/execat.c @@ -36,6 +36,8 @@ struct stat { int st_mode; }; /** * The current environment variables. + * + * @since Always. */ extern char** environ; @@ -52,6 +54,8 @@ extern char** environ; * @param use_path Whether $PATH may be used. * * @throws Any error specified for execve(2). + * + * @since Always. */ static void vexecat(int dirfd, const char* file, va_list argv, int fetch_envp, int use_path) { @@ -107,6 +111,8 @@ static void vexecat(int dirfd, const char* file, va_list argv, int fetch_envp, i * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execlat(int dirfd, const char* path, ... /*, NULL, int flags */) { @@ -152,6 +158,8 @@ int execlat(int dirfd, const char* path, ... /*, NULL, int flags */) * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execlpat(int dirfd, const char* file, ... /*, NULL, int flags */) { @@ -197,6 +205,8 @@ int execlpat(int dirfd, const char* file, ... /*, NULL, int flags */) * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execleat(int dirfd, const char* path, ... /*, NULL, char* const[] envp, int flags */) { @@ -246,6 +256,8 @@ int execleat(int dirfd, const char* path, ... /*, NULL, char* const[] envp, int * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execlpeat(int dirfd, const char* file, ... /*, NULL, char* const[] envp, int flags */) { @@ -291,6 +303,8 @@ int execlpeat(int dirfd, const char* file, ... /*, NULL, char* const[] envp, int * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execvat(int dirfd, const char* path, char* const argv[], int flags) { @@ -334,6 +348,8 @@ int execvat(int dirfd, const char* path, char* const argv[], int flags) * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execvpat(int dirfd, const char* file, char* const argv[], int flags) { @@ -375,6 +391,8 @@ int execvpat(int dirfd, const char* file, char* const argv[], int flags) * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execveat(int dirfd, const char* path, char* const argv[], char* const envp[], int flags) { @@ -451,6 +469,8 @@ int execveat(int dirfd, const char* path, char* const argv[], char* const envp[] * set to describe the error. * * @throws Any error specified for execveat(2). + * + * @since Always. */ int execvpeat(int dirfd, const char* file, char* const argv[], char* const envp[], int flags) { diff --git a/src/unistd/fexec.c b/src/unistd/fexec.c index 7a8d4f5..5277373 100644 --- a/src/unistd/fexec.c +++ b/src/unistd/fexec.c @@ -25,6 +25,8 @@ /** * The current environment variables. + * + * @since Always. */ extern char** environ; @@ -39,6 +41,8 @@ extern char** environ; * @param fetch_envp Whether `argv` includes `envp`. * * @throws Any error specified for execve(2). + * + * @since Always. */ static void vfexec(int fd, va_list argv, int fetch_envp) { @@ -79,6 +83,8 @@ static void vfexec(int fd, va_list argv, int fetch_envp) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int fexecl(int fd, ... /*, NULL */) { @@ -111,6 +117,8 @@ int fexecl(int fd, ... /*, NULL */) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int fexecle(int fd, ... /*, NULL, char* const envp[] */) { @@ -143,6 +151,8 @@ int fexecle(int fd, ... /*, NULL, char* const envp[] */) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int fexecv(int fd, char* const argv[]) { @@ -171,6 +181,8 @@ int fexecv(int fd, char* const argv[]) * set to describe the error. * * @throws Any error specified for execve(2). + * + * @since Always. */ int fexecve(int fd, char* const argv[], char* const envp[]) { diff --git a/src/wchar/rawwcscasestr.c b/src/wchar/rawwcscasestr.c index 51af4ce..e027edb 100644 --- a/src/wchar/rawwcscasestr.c +++ b/src/wchar/rawwcscasestr.c @@ -30,6 +30,8 @@ * @param haystack The string to search. * @param needle The sought after substring. * @return Pointer to the first occurrence of the substring. + * + * @since Always. */ wchar_t* (rawwcscasestr)(const wchar_t* haystack, const wchar_t* needle) { diff --git a/src/wchar/rawwcsstr.c b/src/wchar/rawwcsstr.c index 42450ab..59ec279 100644 --- a/src/wchar/rawwcsstr.c +++ b/src/wchar/rawwcsstr.c @@ -30,6 +30,8 @@ * @param haystack The string to search. * @param needle The sought after substring. * @return Pointer to the first occurrence of the substring. + * + * @since Always. */ wchar_t* (rawwcsstr)(const wchar_t* haystack, const wchar_t* needle) { diff --git a/src/wchar/rawwmemchr.c b/src/wchar/rawwmemchr.c index dafc58b..31818ed 100644 --- a/src/wchar/rawwmemchr.c +++ b/src/wchar/rawwmemchr.c @@ -32,6 +32,8 @@ * @param segment The memory segment to search. * @param c The sought after character. * @return Pointer to the first occurrence of `c`. + * + * @since Always. */ wchar_t* (rawwmemchr)(const wchar_t* segment, wchar_t c) { diff --git a/src/wchar/wcpcpy.c b/src/wchar/wcpcpy.c index 7afbd26..98e6cad 100644 --- a/src/wchar/wcpcpy.c +++ b/src/wchar/wcpcpy.c @@ -28,6 +28,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither + wcslen(whence)` is returned. + * + * @since Always. */ wchar_t* wcpcpy(wchar_t* restrict whither, const wchar_t* restrict whence) { diff --git a/src/wchar/wcpmove.c b/src/wchar/wcpmove.c index bc1e754..1133009 100644 --- a/src/wchar/wcpmove.c +++ b/src/wchar/wcpmove.c @@ -28,6 +28,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither + wcslen(whence)` is returned. + * + * @since Always. */ wchar_t* wcpmove(wchar_t* whither, const wchar_t* whence) { diff --git a/src/wchar/wcpncpy.c b/src/wchar/wcpncpy.c index e291d35..6bfeef2 100644 --- a/src/wchar/wcpncpy.c +++ b/src/wchar/wcpncpy.c @@ -35,6 +35,8 @@ * until this amount of characters have been written. * @return `whither` plus the number of written characters, * excluding NUL characters, is returned. + * + * @since Always. */ wchar_t* wcpncpy(wchar_t* restrict whither, const wchar_t* restrict whence, size_t maxlen) { diff --git a/src/wchar/wcpnmove.c b/src/wchar/wcpnmove.c index 25a591a..799423a 100644 --- a/src/wchar/wcpnmove.c +++ b/src/wchar/wcpnmove.c @@ -36,6 +36,8 @@ * until this amount of characters have been written. * @return `whither` plus the number of written characters, * excluding NUL characters, is returned. + * + * @since Always. */ wchar_t* wcpnmove(wchar_t* whither, const wchar_t* whence, size_t maxlen) { diff --git a/src/wchar/wcscasecmp.c b/src/wchar/wcscasecmp.c index dea8f46..be1b653 100644 --- a/src/wchar/wcscasecmp.c +++ b/src/wchar/wcscasecmp.c @@ -31,6 +31,8 @@ * @param b A positive value is returned if this is the lesser. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int wcscasecmp(const wchar_t* a, const wchar_t* b) { diff --git a/src/wchar/wcscaseends.c b/src/wchar/wcscaseends.c index 93d0cc6..c2df9ad 100644 --- a/src/wchar/wcscaseends.c +++ b/src/wchar/wcscaseends.c @@ -29,6 +29,8 @@ * @param desired The desired ending of the string. * @return The `string`, where `desired` beings if * `string` ends with `desired`, `NULL` otherwise. + * + * @since Always. */ wchar_t* (wcscaseends)(const wchar_t* string, const wchar_t* desired) { diff --git a/src/wchar/wcscasestarts.c b/src/wchar/wcscasestarts.c index bba5881..c613e4e 100644 --- a/src/wchar/wcscasestarts.c +++ b/src/wchar/wcscasestarts.c @@ -29,6 +29,8 @@ * @param desired The desired beginning of the string. * @return `string` if `string` begins with * `desired`, `NULL` otherwise. + * + * @since Always. */ wchar_t* (wcscasestarts)(const wchar_t* string, const wchar_t* desired) { diff --git a/src/wchar/wcscasestr.c b/src/wchar/wcscasestr.c index 3e0e6d0..b637191 100644 --- a/src/wchar/wcscasestr.c +++ b/src/wchar/wcscasestr.c @@ -29,6 +29,8 @@ * @param needle The sought after substring. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ wchar_t* (wcscasestr)(const wchar_t* haystack, const wchar_t* needle) { diff --git a/src/wchar/wcscat.c b/src/wchar/wcscat.c index e6780e4..bb8f727 100644 --- a/src/wchar/wcscat.c +++ b/src/wchar/wcscat.c @@ -28,6 +28,8 @@ * @param whither The string to extend. * @param whence The string to append. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wcscat(wchar_t* restrict whither, const wchar_t* restrict whence) { diff --git a/src/wchar/wcsccpy.c b/src/wchar/wcsccpy.c index e078359..b7e4d98 100644 --- a/src/wchar/wcsccpy.c +++ b/src/wchar/wcsccpy.c @@ -35,6 +35,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcsccpy(wchar_t* restrict whither, const wchar_t* restrict whence, wchar_t c) { diff --git a/src/wchar/wcschr.c b/src/wchar/wcschr.c index 8ebe6c1..5151cc8 100644 --- a/src/wchar/wcschr.c +++ b/src/wchar/wcschr.c @@ -31,6 +31,8 @@ * @param c The sought after character. * @return Pointer to the first occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ wchar_t* (wcschr)(const wchar_t* string, wchar_t c) { diff --git a/src/wchar/wcschrnul.c b/src/wchar/wcschrnul.c index e548e97..9480706 100644 --- a/src/wchar/wcschrnul.c +++ b/src/wchar/wcschrnul.c @@ -36,6 +36,8 @@ * @return Pointer to the first occurrence of `c`, * Pointer to the terminating NUL character * if none were found. + * + * @since Always. */ wchar_t* (wcschrnul)(const wchar_t* string, wchar_t c) { diff --git a/src/wchar/wcscmove.c b/src/wchar/wcscmove.c index 733ec41..7359781 100644 --- a/src/wchar/wcscmove.c +++ b/src/wchar/wcscmove.c @@ -35,6 +35,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcscmove(wchar_t* whither, const wchar_t* whence, wchar_t c) { diff --git a/src/wchar/wcscmp.c b/src/wchar/wcscmp.c index 90ad251..0cc3f7b 100644 --- a/src/wchar/wcscmp.c +++ b/src/wchar/wcscmp.c @@ -26,6 +26,8 @@ * @param b A positive value is returned if this is the lesser. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int wcscmp(const wchar_t* a, const wchar_t* b) { diff --git a/src/wchar/wcscncpy.c b/src/wchar/wcscncpy.c index fe0a14f..6fe5661 100644 --- a/src/wchar/wcscncpy.c +++ b/src/wchar/wcscncpy.c @@ -42,6 +42,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcscncpy(wchar_t* restrict whither, const wchar_t* restrict whence, wchar_t c, size_t maxlen) { diff --git a/src/wchar/wcscnmove.c b/src/wchar/wcscnmove.c index daa518f..83b9ab2 100644 --- a/src/wchar/wcscnmove.c +++ b/src/wchar/wcscnmove.c @@ -42,6 +42,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcscnmove(wchar_t* whither, const wchar_t* whence, wchar_t c, size_t maxlen) { diff --git a/src/wchar/wcscpy.c b/src/wchar/wcscpy.c index 671e894..e5245bd 100644 --- a/src/wchar/wcscpy.c +++ b/src/wchar/wcscpy.c @@ -26,6 +26,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wcscpy(wchar_t* restrict whither, const wchar_t* restrict whence) { diff --git a/src/wchar/wcscspn.c b/src/wchar/wcscspn.c index 5ef1769..31398fe 100644 --- a/src/wchar/wcscspn.c +++ b/src/wchar/wcscspn.c @@ -30,6 +30,8 @@ * @param string The string. * @param stopset Characters disallowed in the substring. * @return The length of the substring. + * + * @since Always. */ size_t wcscspn(const wchar_t* string, const wchar_t* stopset) { diff --git a/src/wchar/wcsdup.c b/src/wchar/wcsdup.c index 62fef76..49f974e 100644 --- a/src/wchar/wcsdup.c +++ b/src/wchar/wcsdup.c @@ -30,6 +30,8 @@ * and `errno` is set to indicate the error. * * @throws ENOMEM The process could not allocate sufficient amount of memory. + * + * @since Always. */ wchar_t* wcsdup(const wchar_t* string) { diff --git a/src/wchar/wcsends.c b/src/wchar/wcsends.c index 2f585f4..72134ca 100644 --- a/src/wchar/wcsends.c +++ b/src/wchar/wcsends.c @@ -29,6 +29,8 @@ * @param desired The desired ending of the string. * @return The `string`, where `desired` beings if * `string` ends with `desired`, `NULL` otherwise. + * + * @since Always. */ wchar_t* (wcsends)(const wchar_t* string, const wchar_t* desired) { diff --git a/src/wchar/wcslen.c b/src/wchar/wcslen.c index 5c0be9f..3597803 100644 --- a/src/wchar/wcslen.c +++ b/src/wchar/wcslen.c @@ -25,6 +25,8 @@ * @param str The string. * @return The number of `wchar_t`:s before the * first NUL character. + * + * @since Always. */ size_t wcslen(const wchar_t* str) { diff --git a/src/wchar/wcsmove.c b/src/wchar/wcsmove.c index 377662c..254745f 100644 --- a/src/wchar/wcsmove.c +++ b/src/wchar/wcsmove.c @@ -28,6 +28,8 @@ * @param whither The destination memory segment. * @param whence The source memory segment. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wcsmove(wchar_t* whither, const wchar_t* whence) { diff --git a/src/wchar/wcsncasecmp.c b/src/wchar/wcsncasecmp.c index 69305ea..3964360 100644 --- a/src/wchar/wcsncasecmp.c +++ b/src/wchar/wcsncasecmp.c @@ -32,6 +32,8 @@ * @param length The maximum number of characters to compare. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int wcsncasecmp(const wchar_t* a, const wchar_t* b, size_t length) { diff --git a/src/wchar/wcsncasestr.c b/src/wchar/wcsncasestr.c index 9818de7..e43009c 100644 --- a/src/wchar/wcsncasestr.c +++ b/src/wchar/wcsncasestr.c @@ -30,6 +30,8 @@ * @param maxlen The maximum number of character to search. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ wchar_t* (wcsncasestr)(const wchar_t* haystack, const wchar_t* needle, size_t maxlen) { diff --git a/src/wchar/wcsncat.c b/src/wchar/wcsncat.c index bd48265..b8de3b4 100644 --- a/src/wchar/wcsncat.c +++ b/src/wchar/wcsncat.c @@ -34,6 +34,8 @@ * shorter, `whither` will be filled with NUL characters * until this amount of characters have been written. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wcsncat(wchar_t* restrict whither, const wchar_t* restrict whence, size_t maxlen) { diff --git a/src/wchar/wcsncmp.c b/src/wchar/wcsncmp.c index c1e5707..1976cc0 100644 --- a/src/wchar/wcsncmp.c +++ b/src/wchar/wcsncmp.c @@ -29,6 +29,8 @@ * @param length The maximum number of characters to compare. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int wcsncmp(const wchar_t* a, const wchar_t* b, size_t length) { diff --git a/src/wchar/wcsncpy.c b/src/wchar/wcsncpy.c index 67631b1..ab6dd5a 100644 --- a/src/wchar/wcsncpy.c +++ b/src/wchar/wcsncpy.c @@ -32,6 +32,8 @@ * shorter, `whither` will be filled with NUL characters * until this amount of characters have been written. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wcsncpy(wchar_t* restrict whither, const wchar_t* restrict whence, size_t maxlen) { diff --git a/src/wchar/wcsndup.c b/src/wchar/wcsndup.c index db81f07..14c95e7 100644 --- a/src/wchar/wcsndup.c +++ b/src/wchar/wcsndup.c @@ -34,6 +34,8 @@ * and `errno` is set to indicate the error. * * @throws ENOMEM The process could not allocate sufficient amount of memory. + * + * @since Always. */ wchar_t* wcsndup(const wchar_t* string, size_t maxlen) { diff --git a/src/wchar/wcsnlen.c b/src/wchar/wcsnlen.c index a094d28..efff94c 100644 --- a/src/wchar/wcsnlen.c +++ b/src/wchar/wcsnlen.c @@ -27,6 +27,8 @@ * @return The number of `wchar_t`:s before the * first NUL character. `maxlen` if no * NUL character was found. + * + * @since Always. */ size_t wcsnlen(const wchar_t* str, size_t maxlen) { diff --git a/src/wchar/wcsnmove.c b/src/wchar/wcsnmove.c index 428a9f5..2af6b46 100644 --- a/src/wchar/wcsnmove.c +++ b/src/wchar/wcsnmove.c @@ -34,6 +34,8 @@ * shorter, `whither` will be filled with NUL characters * until this amount of characters have been written. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wcsnmove(wchar_t* whither, const wchar_t* whence, size_t maxlen) { diff --git a/src/wchar/wcsnstr.c b/src/wchar/wcsnstr.c index 266ebf4..48c34fc 100644 --- a/src/wchar/wcsnstr.c +++ b/src/wchar/wcsnstr.c @@ -31,6 +31,8 @@ * @param maxlen The maximum number of character to search. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ wchar_t* (wcsnstr)(const wchar_t* haystack, const wchar_t* needle, size_t maxlen) { diff --git a/src/wchar/wcspbrk.c b/src/wchar/wcspbrk.c index 1cbb176..064252f 100644 --- a/src/wchar/wcspbrk.c +++ b/src/wchar/wcspbrk.c @@ -33,6 +33,8 @@ * @return A pointer to the first occurrence in * `string` of a character found in `stopset`. * `NULL` is returned if none is found. + * + * @since Always. */ wchar_t* (wcspbrk)(const wchar_t* string, const wchar_t* stopset) { diff --git a/src/wchar/wcsrchr.c b/src/wchar/wcsrchr.c index 3f6e84c..d3af0b1 100644 --- a/src/wchar/wcsrchr.c +++ b/src/wchar/wcsrchr.c @@ -35,6 +35,8 @@ * @param c The sought after character. * @return Pointer to the last occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ wchar_t* (wcsrchr)(const wchar_t* string, wchar_t c) { diff --git a/src/wchar/wcssep.c b/src/wchar/wcssep.c index 9e3f285..e757411 100644 --- a/src/wchar/wcssep.c +++ b/src/wchar/wcssep.c @@ -35,6 +35,8 @@ * `NULL` is returned the search as reached * the end of the string, and there therefore * are no more tokens. + * + * @since Always. */ wchar_t* wcssep(wchar_t** restrict string, const wchar_t* restrict delimiters) { diff --git a/src/wchar/wcsset.c b/src/wchar/wcsset.c index 07639f4..54fedad 100644 --- a/src/wchar/wcsset.c +++ b/src/wchar/wcsset.c @@ -28,6 +28,8 @@ * @param str The beginning of the memory segment. * @param c The wide character. * @return `str` is returned. + * + * @since Always. */ wchar_t* wcsset(wchar_t* str, wchar_t c) { diff --git a/src/wchar/wcsspn.c b/src/wchar/wcsspn.c index 4a023d5..3e9ddd2 100644 --- a/src/wchar/wcsspn.c +++ b/src/wchar/wcsspn.c @@ -30,6 +30,8 @@ * @param string The string. * @param skipset Characters allowed in the substring. * @return The length of the substring. + * + * @since Always. */ size_t wcsspn(const wchar_t* string, const wchar_t* skipset) { diff --git a/src/wchar/wcsstarts.c b/src/wchar/wcsstarts.c index 0b000af..cff8a1d 100644 --- a/src/wchar/wcsstarts.c +++ b/src/wchar/wcsstarts.c @@ -29,6 +29,8 @@ * @param desired The desired beginning of the string. * @return `string` if `string` begins with * `desired`, `NULL` otherwise. + * + * @since Always. */ wchar_t* (wcsstarts)(const wchar_t* string, const wchar_t* desired) { diff --git a/src/wchar/wcsstr.c b/src/wchar/wcsstr.c index e88530d..a933dc0 100644 --- a/src/wchar/wcsstr.c +++ b/src/wchar/wcsstr.c @@ -27,6 +27,8 @@ * @param needle The sought after substring. * @return Pointer to the first occurrence of the * substring, `NULL` if not found. + * + * @since Always. */ wchar_t* (wcsstr)(const wchar_t* haystack, const wchar_t* needle) { diff --git a/src/wchar/wcsstrcpy.c b/src/wchar/wcsstrcpy.c index 1b694b5..9ec99b1 100644 --- a/src/wchar/wcsstrcpy.c +++ b/src/wchar/wcsstrcpy.c @@ -34,6 +34,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcsstrcpy(wchar_t* restrict whither, const wchar_t* restrict whence, const wchar_t* restrict str) { diff --git a/src/wchar/wcsstrmove.c b/src/wchar/wcsstrmove.c index 9509a05..3861dbd 100644 --- a/src/wchar/wcsstrmove.c +++ b/src/wchar/wcsstrmove.c @@ -34,6 +34,8 @@ * number of copied characters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcsstrmove(wchar_t* whither, const wchar_t* whence, const wchar_t* restrict str) { diff --git a/src/wchar/wcsstrncpy.c b/src/wchar/wcsstrncpy.c index 62ed24c..434827f 100644 --- a/src/wchar/wcsstrncpy.c +++ b/src/wchar/wcsstrncpy.c @@ -41,6 +41,8 @@ * number of copied chartacters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcsstrncpy(wchar_t* restrict whither, const wchar_t* restrict whence, const wchar_t* restrict str, size_t maxlen) diff --git a/src/wchar/wcsstrnmove.c b/src/wchar/wcsstrnmove.c index d72bd9c..72801ee 100644 --- a/src/wchar/wcsstrnmove.c +++ b/src/wchar/wcsstrnmove.c @@ -41,6 +41,8 @@ * number of copied chartacters; the address of * one character passed the last written non-NUL * character. + * + * @since Always. */ wchar_t* wcsstrnmove(wchar_t* whither, const wchar_t* whence, const wchar_t* restrict str, size_t maxlen) { diff --git a/src/wchar/wcstok.c b/src/wchar/wcstok.c index dbf0c5f..a074bc3 100644 --- a/src/wchar/wcstok.c +++ b/src/wchar/wcstok.c @@ -37,6 +37,8 @@ * `NULL` is returned the search as reached * the end of the string, and there therefore * are no more tokens. + * + * @since Always. */ wchar_t* wcstok(wchar_t* restrict string, const wchar_t* restrict delimiters, wchar_t** restrict state) diff --git a/src/wchar/wcswcs.c b/src/wchar/wcswcs.c index 339ec2f..91c1c49 100644 --- a/src/wchar/wcswcs.c +++ b/src/wchar/wcswcs.c @@ -21,6 +21,8 @@ /** * This function is identical to `wcsstr`. + * + * @since Always. */ wchar_t* (wcswcs)(const wchar_t* haystack, const wchar_t* needle) { diff --git a/src/wchar/wmemcasecmp.c b/src/wchar/wmemcasecmp.c index 8672bbb..53f8a46 100644 --- a/src/wchar/wmemcasecmp.c +++ b/src/wchar/wmemcasecmp.c @@ -28,6 +28,8 @@ * @param size The size of the segments. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int wmemcasecmp(const wchar_t* a, const wchar_t* b, size_t size) { diff --git a/src/wchar/wmemcasemem.c b/src/wchar/wmemcasemem.c index d01fda8..05a9734 100644 --- a/src/wchar/wmemcasemem.c +++ b/src/wchar/wmemcasemem.c @@ -39,6 +39,8 @@ * @param needle_length The length of `needle`. * @return Pointer to the first occurrence of * the substring, `NULL` if not found. + * + * @since Always. */ wchar_t* (wmemcasemem)(const wchar_t* haystack, size_t haystack_length, const wchar_t* needle, size_t needle_length) diff --git a/src/wchar/wmemccpy.c b/src/wchar/wmemccpy.c index a6eb7ca..4dfde01 100644 --- a/src/wchar/wmemccpy.c +++ b/src/wchar/wmemccpy.c @@ -34,6 +34,8 @@ * that is, the address of `whither` plus the * number of copied characters; the address of * one character passed the last written character. + * + * @since Always. */ wchar_t* wmemccpy(wchar_t* restrict whither, const wchar_t* restrict whence, wchar_t c, size_t size) { diff --git a/src/wchar/wmemchr.c b/src/wchar/wmemchr.c index 9dd3e5f..a1c8b98 100644 --- a/src/wchar/wmemchr.c +++ b/src/wchar/wmemchr.c @@ -31,6 +31,8 @@ * @param size The size of the memory segment. * @return Pointer to the first occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ wchar_t* (wmemchr)(const wchar_t* segment, wchar_t c, size_t size) { diff --git a/src/wchar/wmemcmove.c b/src/wchar/wmemcmove.c index a86138f..cdc35c2 100644 --- a/src/wchar/wmemcmove.c +++ b/src/wchar/wmemcmove.c @@ -34,6 +34,8 @@ * that is, the address of `whither` plus the * number of copied characters; the address of * one character passed the last written character. + * + * @since Always. */ wchar_t* wmemcmove(wchar_t* whither, const wchar_t* whence, wchar_t c, size_t size) { diff --git a/src/wchar/wmemcmp.c b/src/wchar/wmemcmp.c index 9bfe6b3..e912e57 100644 --- a/src/wchar/wmemcmp.c +++ b/src/wchar/wmemcmp.c @@ -27,6 +27,8 @@ * @param size The size of the segments. * @return Zero is returned if `a` and `b` are equal, otherwise, * see the specifications for `a` and `b`. + * + * @since Always. */ int wmemcmp(const wchar_t* a, const wchar_t* b, size_t size) { diff --git a/src/wchar/wmemcpy.c b/src/wchar/wmemcpy.c index bcae22a..124f38c 100644 --- a/src/wchar/wmemcpy.c +++ b/src/wchar/wmemcpy.c @@ -26,6 +26,8 @@ * @param whence The source memory segment. * @param size The number of wide characters to copy. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wmemcpy(wchar_t* restrict whither, const wchar_t* restrict whence, size_t size) { diff --git a/src/wchar/wmemdup.c b/src/wchar/wmemdup.c index 196009b..b02ff27 100644 --- a/src/wchar/wmemdup.c +++ b/src/wchar/wmemdup.c @@ -31,6 +31,8 @@ * and `errno` is set to indicate the error. * * @throws ENOMEM The process could not allocate sufficient amount of memory. + * + * @since Always. */ wchar_t* wmemdup(const wchar_t* segment, size_t size) { diff --git a/src/wchar/wmemmem.c b/src/wchar/wmemmem.c index bd32035..c0afe85 100644 --- a/src/wchar/wmemmem.c +++ b/src/wchar/wmemmem.c @@ -39,6 +39,8 @@ * @param needle_length The length of `needle`. * @return Pointer to the first occurrence of * the substring, `NULL` if not found. + * + * @since Always. */ wchar_t* (wmemmem)(const wchar_t* haystack, size_t haystack_length, const wchar_t* needle, size_t needle_length) diff --git a/src/wchar/wmemmove.c b/src/wchar/wmemmove.c index b531468..70ce283 100644 --- a/src/wchar/wmemmove.c +++ b/src/wchar/wmemmove.c @@ -28,6 +28,8 @@ * @param whence The source memory segment. * @param size The number of wide characters to copy. * @return `whither` is returned. + * + * @since Always. */ wchar_t* wmemmove(wchar_t* whither, const wchar_t* whence, size_t size) { diff --git a/src/wchar/wmempcpy.c b/src/wchar/wmempcpy.c index 0cd419c..acc05a3 100644 --- a/src/wchar/wmempcpy.c +++ b/src/wchar/wmempcpy.c @@ -28,6 +28,8 @@ * @param whence The source memory segment. * @param size The number of wide characters to copy. * @return `whither + size` is returned. + * + * @since Always. */ wchar_t* wmempcpy(wchar_t* restrict whither, const wchar_t* restrict whence, size_t size) { diff --git a/src/wchar/wmempmove.c b/src/wchar/wmempmove.c index 2d5ecd4..36f3123 100644 --- a/src/wchar/wmempmove.c +++ b/src/wchar/wmempmove.c @@ -29,6 +29,8 @@ * @param whence The source memory segment. * @param size The number of wide characters to copy. * @return `whither + size` is returned. + * + * @since Always. */ wchar_t* wmempmove(wchar_t* whither, const wchar_t* whence, size_t size) { diff --git a/src/wchar/wmemrchr.c b/src/wchar/wmemrchr.c index b41e666..2ad53d5 100644 --- a/src/wchar/wmemrchr.c +++ b/src/wchar/wmemrchr.c @@ -37,6 +37,8 @@ * @param size The size of the memory segment. * @return Pointer to the last occurrence of `c`, * `NULL` if none were found. + * + * @since Always. */ wchar_t* (wmemrchr)(const wchar_t* segment, wchar_t c, size_t size) { diff --git a/src/wchar/wmemset.c b/src/wchar/wmemset.c index 95ec70f..83b4706 100644 --- a/src/wchar/wmemset.c +++ b/src/wchar/wmemset.c @@ -26,6 +26,8 @@ * @param c The wide character. * @param size The number of wide characters in the memory segment. * @return `segment` is returned. + * + * @since Always. */ wchar_t* wmemset(wchar_t* segment, wchar_t c, size_t size) { |