Context-free sorting function. More...
#include <stddef.h>
Go to the source code of this file.
Typedefs | |
typedef int(* | sort_t) (const void *a, const void *b, void *sdata) |
Functions | |
void | mutt_qsort_r (void *base, size_t nmemb, size_t size, sort_t compar, void *sdata) |
Sort an array, where the comparator has access to opaque data rather than requiring global variables. | |
Context-free sorting function.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file qsort_r.h.
typedef int(* sort_t) (const void *a, const void *b, void *sdata) |
void mutt_qsort_r | ( | void * | base, |
size_t | nmemb, | ||
size_t | size, | ||
sort_t | compar, | ||
void * | sdata | ||
) |
Sort an array, where the comparator has access to opaque data rather than requiring global variables.
base | Start of the array to be sorted |
nmemb | Number of elements in the array |
size | Size of each array element |
compar | Comparison function, return <0/0/>0 to compare two elements |
sdata | Opaque argument to pass to compar |
Definition at line 67 of file qsort_r.c.