Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • async: asynchronously start a new task to execute a statement.
  • finish: execute a statement, but wait until all (transitively) spawned asyncs in statement's scope have terminated.

A simple HelloWorld example


Code Block
languagecpp
titleHC HelloWorld
linenumberstrue
#include <stdio.h>
int main (int argc, char ** argv) {
  finish {
    async {
      printf("Hello World !\n");
    }
  }
  return 0;
}

...