diff -r 1dbbf8c1c42f -r f8ca6e6c0d48 src/cx/list.h --- a/src/cx/list.h Mon Sep 16 19:52:17 2024 +0200 +++ b/src/cx/list.h Tue Sep 17 19:08:22 2024 +0200 @@ -256,6 +256,8 @@ * @param list the list in which to swap * @param i index of one element * @param j index of the other element + * @return zero on success, non-zero when indices are out of bounds or memory + * allocation for the temporary buffer fails */ __attribute__((__nonnull__)) int cx_list_default_swap(struct cx_list_s *list, size_t i, size_t j);