[REBOL] Re: No-wait

2004-02-23 Thread Paul Tretter
- Original Message - From: "Andreas Bolka" <[EMAIL PROTECTED]> To: "Paul Tretter" <[EMAIL PROTECTED]> Sent: Monday, February 23, 2004 4:07 PM Subject: [REBOL] Re: No-wait > > > Monday, February 23, 2004, 9:47:33 PM, Paul wrote: > > > However, I wa

[REBOL] Re: No-wait

2004-02-23 Thread Andreas Bolka
Monday, February 23, 2004, 9:47:33 PM, Paul wrote: > However, I was using the small reference of code to demonstrate the > blocking aspect of the port despite no-wait. So I have a fix for my > problem but not a good definition of what no-wait does. From /core > docs: > Nowait port will no

[REBOL] Re: No-wait

2004-02-23 Thread Paul Tretter
ROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, February 23, 2004 8:19 AM Subject: [REBOL] Re: No-wait > > Paul Tretter napsal(a): > > >Yeah this was my current work around to use 0 as a timeout but I was a > >wondering why it was needed if there was no-wait. > >

[REBOL] Re: No-wait

2004-02-23 Thread Andreas Bolka
Monday, February 23, 2004, 4:31:01 AM, Paul wrote: > Even that still blocks. Need a way of not waiting for the port data > if nothing is there. But here, only the "accept" (i.e. the wait on the listen port) blocks. You can overcome this by adding a "timeout": port: open/direct/no-wait tcp://

[REBOL] Re: No-wait

2004-02-23 Thread Petr Krenzelok
Paul Tretter napsal(a): >Yeah this was my current work around to use 0 as a timeout but I was a >wondering why it was needed if there was no-wait. > > It was not imo. Your code was imo wrong for what you wanted to achieve: port: open/direct/no-wait tcp://:7000 x: 0 forever [ print x + 1

[REBOL] Re: No-wait

2004-02-23 Thread Paul Tretter
Yeah this was my current work around to use 0 as a timeout but I was a wondering why it was needed if there was no-wait. Paul - Original Message - From: "Volker Nitsch" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, February 23, 2004 4:51 AM Subjec

[REBOL] Re: No-wait

2004-02-23 Thread Paul Tretter
: "Gabriele Santilli" <[EMAIL PROTECTED]> To: "Paul Tretter" <[EMAIL PROTECTED]> Sent: Monday, February 23, 2004 5:14 AM Subject: [REBOL] Re: No-wait > > Hi Paul, > > On Monday, February 23, 2004, 4:31:01 AM, you wrote: > > PT> Even that still blocks.

[REBOL] Re: No-wait

2004-02-23 Thread Gabriele Santilli
Hi Paul, On Monday, February 23, 2004, 4:31:01 AM, you wrote: PT> Even that still blocks. Need a way of not waiting for the port data if PT> nothing is there. A way to just continue processing the rest of the forever PT> loop which should be continously print the current value of x. Maybe, I

[REBOL] Re: No-wait

2004-02-23 Thread Volker Nitsch
Am Sonntag, 22. Februar 2004 20:49 schrieben Sie: > What is the purpose of no-wait. Doesn't seem work for me. Isn't no wait > supposed to return immediately. > > For example: > > Shouldn't a forever loop that has the following code always be printing > instead of only once the port has received

[REBOL] Re: No-wait

2004-02-22 Thread Paul Tretter
- Original Message - From: "Andreas Bolka" <[EMAIL PROTECTED]> To: "Paul Tretter" <[EMAIL PROTECTED]> Sent: Sunday, February 22, 2004 6:41 PM Subject: [REBOL] Re: No-wait > > > Sunday, February 22, 2004, 10:42:06 PM, Paul wrote: > > > Problem is

[REBOL] Re: No-wait

2004-02-22 Thread Andreas Bolka
Sunday, February 22, 2004, 10:42:06 PM, Paul wrote: > Problem is that when I try copy I get: > ** Script Error: Cannot use copy on this type port > ** Where: forever > ** Near: data: copy port Your example was: port: open/direct/no-wait tcp://:7000 x: 0 forever [ print x + 1

[REBOL] Re: No-wait

2004-02-22 Thread Paul Tretter
IL PROTECTED]> Sent: Sunday, February 22, 2004 4:12 PM Subject: [REBOL] Re: No-wait > > That *is* strange. > > --Maarten > > Paul Tretter wrote: > > >Problem is that when I try copy I get: > > > >* Script Error: Cannot use copy on this type port > &g

[REBOL] Re: No-wait

2004-02-22 Thread Romano Paolo Tenca
listen port are always wait (afaik) you should use the awake port field for async code --- Ciao Romano - Original Message - From: "Paul Tretter" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, February 22, 2004 8:49 PM Subject: [REBOL] No-wait > What is the purpose of no-wa

[REBOL] Re: No-wait

2004-02-22 Thread Maarten Koopmans
s" <[EMAIL PROTECTED]> >To: <[EMAIL PROTECTED]> >Sent: Sunday, February 22, 2004 2:18 PM >Subject: [REBOL] Re: No-wait > > > > >>No-wait modifies the behaviour of 'copy, not 'wait. >>Copy doesn't block, but returns immediately with

[REBOL] Re: No-wait

2004-02-22 Thread Petr Krenzelok
Maarten Koopmans wrote: >No-wait modifies the behaviour of 'copy, not 'wait. >Copy doesn't block, but returns immediately with an empty string if >there is no data. > >BTW: I found that it works best to have buffering on in TCP ports. > > Could you explain, please? I would not expect it being

[REBOL] Re: No-wait

2004-02-22 Thread Paul Tretter
, 2004 2:18 PM Subject: [REBOL] Re: No-wait > > No-wait modifies the behaviour of 'copy, not 'wait. > Copy doesn't block, but returns immediately with an empty string if > there is no data. > > BTW: I found that it works best to have buffering on in TCP ports. &g

[REBOL] Re: No-wait

2004-02-22 Thread Maarten Koopmans
No-wait modifies the behaviour of 'copy, not 'wait. Copy doesn't block, but returns immediately with an empty string if there is no data. BTW: I found that it works best to have buffering on in TCP ports. --Maarten Paul Tretter wrote: >What is the purpose of no-wait. Doesn't seem work for me