Re: [Factor-talk] Wait for Thread

2017-12-20 Thread Chris Double
The easiest way might be to use futures:
http://docs.factorcode.org/content/article-concurrency.futures.html

eg:

[ 42 ] future ?future .
=> 42


On Thu, Dec 21, 2017 at 10:44 AM, Alexander Ilin  wrote:
> Hello!
>
>   If I spawn a thread using the threads:spawn word, is there a way to wait 
> for the thread to finish its work?
>   I need something like WaitForSingleObject(ThreadHandle, INFINITE).
>
> ---=---
>  Александр
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Factor-talk mailing list
> Factor-talk@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/factor-talk

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk


[Factor-talk] Wait for Thread

2017-12-20 Thread Alexander Ilin
Hello!

  If I spawn a thread using the threads:spawn word, is there a way to wait for 
the thread to finish its work?
  I need something like WaitForSingleObject(ThreadHandle, INFINITE).

---=--- 
 Александр

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Factor-talk mailing list
Factor-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/factor-talk