]> git.ozlabs.org Git - ccan/blob - ccan/order/test/compile_ok.c
order: Module for comparison callbacks
[ccan] / ccan / order / test / compile_ok.c
1 #include <stdlib.h>
2 #include <string.h>
3 #include <stdio.h>
4
5 #include <ccan/order/order.h>
6
7 #include "fancy_cmp.h"
8
9 int main(int argc, char *argv[])
10 {
11         total_order_cb(cb0, struct item, struct cmp_info *) = fancy_cmp;
12         _total_order_cb cb1 = total_order_cast(fancy_cmp,
13                                                struct item, struct cmp_info *);
14         total_order_noctx_cb cb_noctx = fancy_cmp_noctx;
15
16         printf("%p %p %p\n", cb0, cb1, cb_noctx);
17
18         exit(0);
19 }