6 * coroutine - Co-routines
8 * This code has helper functions for implementing co-routines, that
9 * is, explicit co-operative context switching. It's intended to
10 * provide similar functionality to ucontext, but with a cleaner
11 * interface. At the moment this is implemented in terms of ucontext,
12 * but the hope is to add other implementations for platforms that
13 * don't have ucontext in future.
15 * Author: David Gibson <david@gibson.dropbear.id.au>
16 * License: LGPL (v2.1 or any later version)
19 * // Context switching really confuses valgrind
20 * tests_pass_valgrind FAIL
22 int main(int argc, char *argv[])
24 /* Expect exactly one argument */
28 if (strcmp(argv[1], "depends") == 0) {
29 printf("ccan/ptrint\n");
30 printf("ccan/compiler\n");
31 printf("ccan/build_assert\n");
32 printf("ccan/typesafe_cb\n");
36 if (strcmp(argv[1], "ported") == 0) {
38 printf("Requires working ucontext.h\n");