X-Git-Url: http://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=ccan%2Flpq%2F_info;fp=ccan%2Flpq%2F_info;h=08dcda9b8b3f9a8f6c059ea3334f65fe63af22d6;hp=0000000000000000000000000000000000000000;hb=195e8492de575a352f8bb38bbfedaf6f27902e40;hpb=42b7ab487d38ac9753cc2fd3264f24082cff5b05 diff --git a/ccan/lpq/_info b/ccan/lpq/_info new file mode 100644 index 00000000..08dcda9b --- /dev/null +++ b/ccan/lpq/_info @@ -0,0 +1,40 @@ +#include "config.h" +#include +#include + +/** + * lpq - Simple, slow priority queue implementation + * + * This code implements a priority queue. This is a trivial linked + * list implementation, which is simple and generally slow. + * + * init: O(1) + * enqueue: O(1) + * front: O(n) + * dequeue: O(n) + * reorder: O(1) + * + * Author: David Gibson + * License: LGPL (v2.1 or any later version) + */ +int main(int argc, char *argv[]) +{ + /* Expect exactly one argument */ + if (argc != 2) + return 1; + + if (strcmp(argv[1], "depends") == 0) { + printf("ccan/tcon\n"); + printf("ccan/order\n"); + printf("ccan/cast\n"); + return 0; + } + + if (strcmp(argv[1], "testdepends") == 0) { + printf("ccan/permutation\n"); + printf("ccan/array_size\n"); + return 0; + } + + return 1; +}