Guest User

Untitled

a guest
Sep 16th, 2015
232
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. void
  2. receive(chan(byte*) c)
  3. {
  4.     byte *s;
  5.     s = <-c;
  6.     print("%s\n", s);
  7.     terminate(nil);
  8. }
  9.  
  10. void
  11. main(void)
  12. {
  13.     chan(byte*) c;
  14.     alloc c;
  15.     proc receive(c);
  16.     c <-= "Hello, World!";
  17.     terminate(nil);
  18. }
RAW Paste Data