X-Git-Url: https://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=ccan%2Fhashtable%2Ftest%2Fcompile_ok-traverse.c;fp=ccan%2Fhashtable%2Ftest%2Fcompile_ok-traverse.c;h=0000000000000000000000000000000000000000;hp=365180d4a377348b37636f999dbcc3a064b8447b;hb=e81b19896fc782b5e9288b16a5311d4ff8ac4cec;hpb=0473813acdfad62221ec9f2b9b41bc10d1f4586d diff --git a/ccan/hashtable/test/compile_ok-traverse.c b/ccan/hashtable/test/compile_ok-traverse.c deleted file mode 100644 index 365180d4..00000000 --- a/ccan/hashtable/test/compile_ok-traverse.c +++ /dev/null @@ -1,49 +0,0 @@ -#include -#include - -struct foo { - int i; -}; - -struct bar { - int i; -}; - -static bool fn_foo_bar(struct foo *foo, struct bar *bar) -{ - return true; -} - -static bool fn_const_foo_bar(const struct foo *foo, struct bar *bar) -{ - return true; -} - -static bool fn_foo_const_bar(struct foo *foo, const struct bar *bar) -{ - return true; -} - -static bool fn_const_foo_const_bar(const struct foo *foo, - const struct bar *bar) -{ - return true; -} - -static bool fn_void_void(void *foo, void *bar) -{ - return true; -} - -int main(void) -{ - struct hashtable *ht = NULL; - struct bar *bar = NULL; - - hashtable_traverse(ht, struct foo, fn_foo_bar, bar); - hashtable_traverse(ht, struct foo, fn_const_foo_bar, bar); - hashtable_traverse(ht, struct foo, fn_foo_const_bar, bar); - hashtable_traverse(ht, struct foo, fn_const_foo_const_bar, bar); - hashtable_traverse(ht, struct foo, fn_void_void, bar); - return 0; -}