From 399da01ae4eb5c5e3e9349bacc2063c946c3d4a1 Mon Sep 17 00:00:00 2001 From: Bo Yang Date: Tue, 11 Aug 2009 11:17:23 +0000 Subject: Merge the branches/struggleyb/libdom-remain back to trunk. svn path=/trunk/dom/; revision=9191 --- test/testutils/comparators.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 test/testutils/comparators.h (limited to 'test/testutils/comparators.h') diff --git a/test/testutils/comparators.h b/test/testutils/comparators.h new file mode 100644 index 0000000..cad79e1 --- /dev/null +++ b/test/testutils/comparators.h @@ -0,0 +1,23 @@ +/* + * This file is part of libdom test suite. + * Licensed under the MIT License, + * http://www.opensource.org/licenses/mit-license.php + * Copyright 2007 James Shaw + * Copyright 2009 Bo Yang + */ + +#ifndef comparators_h_ +#define comparators_h_ + +/** + * A function pointer type for a comparator. + */ +typedef int (*comparator)(const void* a, const void* b); + +int int_comparator(const void* a, const void* b); + +int str_icmp(const void *a, const void *b); +int str_icmp_r(const void *a, const void *b); +int str_cmp(const void *a, const void *b); +int str_cmp_r(const void *a, const void *b); +#endif -- cgit v1.2.3