Advertisement
Guest User

Untitled

a guest
Oct 7th, 2017
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Vala 0.28 KB | None | 0 0
  1.  
  2. async void test(){
  3.     string foo = "somestring";
  4.    
  5.     ThreadFunc<void*> run = () => {
  6.         stdout.printf("Value: %s\n", foo);
  7.         return null;
  8.     };
  9.  
  10.     Thread.create<void*>(run, false);
  11.  
  12. }
  13.  
  14.  
  15.  
  16. void main(string[] args){
  17.     test.begin();
  18.  
  19.     MainLoop l = new MainLoop();
  20.     l.run();
  21.  
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement