Use algorithm with dictionary too.
This commit is contained in:
1 parent
7eb26a29f1
commit
1eb0e8730d
1 file changed
+5
-1
+5
-1
@@ -25,9 +25,11 @@
|
|||||||
#include "m-array.h"
|
#include "m-array.h"
|
||||||
#include "m-string.h"
|
#include "m-string.h"
|
||||||
#include "m-deque.h"
|
#include "m-deque.h"
|
||||||
#include "test-obj.h"
|
#include "m-dict.h"
|
||||||
#include "m-algo.h"
|
#include "m-algo.h"
|
||||||
|
|
||||||
|
#include "test-obj.h"
|
||||||
|
|
||||||
typedef struct over_s {
|
typedef struct over_s {
|
||||||
unsigned long data;
|
unsigned long data;
|
||||||
ILIST_INTERFACE(ilist_over, over_s);
|
ILIST_INTERFACE(ilist_over, over_s);
|
||||||
@@ -42,6 +44,7 @@ ILIST_DEF(ilist_over, over_t, M_POD_OPLIST)
|
|||||||
LIST_DEF(list_string, string_t, STRING_OPLIST)
|
LIST_DEF(list_string, string_t, STRING_OPLIST)
|
||||||
DEQUE_DEF(deque_obj, testobj_t, TESTOBJ_CMP_OPLIST)
|
DEQUE_DEF(deque_obj, testobj_t, TESTOBJ_CMP_OPLIST)
|
||||||
#define M_OPL_deque_obj_t() DEQUE_OPLIST(deque_obj, TESTOBJ_CMP_OPLIST)
|
#define M_OPL_deque_obj_t() DEQUE_OPLIST(deque_obj, TESTOBJ_CMP_OPLIST)
|
||||||
|
DICT_DEF2(dict_obj, string_t, STRING_OPLIST, testobj_t, TESTOBJ_OPLIST)
|
||||||
|
|
||||||
#include "coverage.h"
|
#include "coverage.h"
|
||||||
START_COVERAGE
|
START_COVERAGE
|
||||||
@@ -50,6 +53,7 @@ ALGO_DEF(algo_list, LIST_OPLIST(list_int))
|
|||||||
ALGO_DEF(algo_over, ILIST_OPLIST(ilist_over, M_POD_OPLIST))
|
ALGO_DEF(algo_over, ILIST_OPLIST(ilist_over, M_POD_OPLIST))
|
||||||
ALGO_DEF(algo_string, LIST_OPLIST(list_string, STRING_OPLIST))
|
ALGO_DEF(algo_string, LIST_OPLIST(list_string, STRING_OPLIST))
|
||||||
ALGO_DEF(algo_deque, deque_obj_t)
|
ALGO_DEF(algo_deque, deque_obj_t)
|
||||||
|
ALGO_DEF(algo_dict, DICT_OPLIST(dict_obj, STRING_OPLIST, TESTOBJ_OPLIST))
|
||||||
END_COVERAGE
|
END_COVERAGE
|
||||||
|
|
||||||
int g_min, g_max, g_count;
|
int g_min, g_max, g_count;
|
||||||
|
|||||||
Reference in new issue
Block a user