1. Euphoria's "sleep(0)" call
- Posted by Al Getz <Xaxo at aol.com> Sep 25, 2005
- 484 views
Hello there, In misc.e, sleep(0) is wrapped to return if x is zero (0). In WinAPI, sleep(0) yields control to another process. What im wondering is, if we change the code to allow the 'machine' function to allow the call even with zero (0) will it yield control like the Win API call or no? Take care, Al And, good luck with your Euphoria programming! My bumper sticker: "I brake for LED's"
2. Re: Euphoria's "sleep(0)" call
- Posted by "Juergen Luethje" <j.lue at gmx.de> Sep 25, 2005
- 489 views
Al Getz wrote: > In misc.e, sleep(0) is wrapped to return if x is zero (0). I think that was the case in Eu versions prior to 2.5. > In WinAPI, sleep(0) yields control to another process. > What im wondering is, if we change the code to allow the > 'machine' function to allow the call even with zero (0) This is already the case in Eu 2.5. In 'misc.e' it reads:
global procedure sleep(integer t) -- go to sleep for t seconds -- allowing (on WIN32 and Linux) other processes to run if t >= 0 then machine_proc(M_SLEEP, t) end if end procedure
> will it yield control like the Win API call or no? I don't know. Regards, Juergen
3. Re: Euphoria's "sleep(0)" call
- Posted by Al Getz <Xaxo at aol.com> Sep 25, 2005
- 487 views
Juergen Luethje wrote: > > Al Getz wrote: > > > In misc.e, sleep(0) is wrapped to return if x is zero (0). > > I think that was the case in Eu versions prior to 2.5. > > > In WinAPI, sleep(0) yields control to another process. > > What im wondering is, if we change the code to allow the > > 'machine' function to allow the call even with zero (0) > > This is already the case in Eu 2.5. In 'misc.e' it reads: > > }}} <eucode> > global procedure sleep(integer t) > -- go to sleep for t seconds > -- allowing (on WIN32 and Linux) other processes to run > if t >= 0 then > machine_proc(M_SLEEP, t) > end if > end procedure > </eucode> {{{ > > > will it yield control like the Win API call or no? > > I don't know. > > Regards, > Juergen > > Oh yes, v2.5 has the update. I was looking at v2.4's misc.e :) Take care, Al And, good luck with your Euphoria programming! My bumper sticker: "I brake for LED's"