$ diff -u lispworks.lisp_orig lispworks.lisp_patched --- lispworks.lisp_orig 2009-09-30 11:42:22.000000000 +0200 +++ lispworks.lisp_patched 2009-09-30 19:06:22.118317238 +0200 @@ -90,14 +90,14 @@ (defun make-socket-stream (socket acceptor) "Returns a stream for the socket SOCKET. The ACCEPTOR argument is used to set the timeouts." - #-:lispworks5 + #+:lispworks4 (when (acceptor-write-timeout acceptor) (parameter-error "You need LispWorks 5 or higher for write timeouts.")) (make-instance 'comm:socket-stream :socket socket :direction :io :read-timeout (acceptor-read-timeout acceptor) - #+:lispworks5 #+:lispworks5 + #-:lispworks4 :write-timeout (acceptor-write-timeout acceptor) :element-type 'octet))
The patch does not look as if it worked for the Lispworks 4 case. Is LW 4 still in use? It might be sensible to remove support for it instead, but that'd be basically Edi's call.
-Hans
On Wed, Sep 30, 2009 at 10:24, Nico de Jager ndj@bitart.cc wrote:
$ diff -u lispworks.lisp_orig lispworks.lisp_patched --- lispworks.lisp_orig 2009-09-30 11:42:22.000000000 +0200 +++ lispworks.lisp_patched 2009-09-30 19:06:22.118317238 +0200 @@ -90,14 +90,14 @@ (defun make-socket-stream (socket acceptor) "Returns a stream for the socket SOCKET. The ACCEPTOR argument is used to set the timeouts."
- #-:lispworks5
- #+:lispworks4
(when (acceptor-write-timeout acceptor) (parameter-error "You need LispWorks 5 or higher for write timeouts.")) (make-instance 'comm:socket-stream :socket socket :direction :io :read-timeout (acceptor-read-timeout acceptor)
- #+:lispworks5 #+:lispworks5
- #-:lispworks4
:write-timeout (acceptor-write-timeout acceptor) :element-type 'octet))
tbnl-devel site list tbnl-devel@common-lisp.net http://common-lisp.net/mailman/listinfo/tbnl-devel
On Thu, Oct 1, 2009 at 1:04 AM, Hans Hübner hans.huebner@gmail.com wrote:
The patch does not look as if it worked for the Lispworks 4 case.
LW4 didn't have write timeouts (and, yes, I think some people still use it).
I guess Nico wanted to have #- instead of #+ in there, but I think it's safer, although a bit more clumsy, to specifically mention LW5 and LW6 (which, as we know from the ECLM, will be released soon).
Thanks, Edi.
Hi Edi & Hans!
Hans Hübner hans.huebner@gmail.com writes:
The patch does not look as if it worked for the Lispworks 4 case.
No, it is meant to work for LispWorks 4.x as well, see below.
Is LW 4 still in use? It might be sensible to remove support for it instead, but that'd be basically Edi's call.
-Hans
On Wed, Sep 30, 2009 at 10:24, Nico de Jager ndj@bitart.cc wrote:
$ diff -u lispworks.lisp_orig lispworks.lisp_patched --- lispworks.lisp_orig 2009-09-30 11:42:22.000000000 +0200 +++ lispworks.lisp_patched 2009-09-30 19:06:22.118317238 +0200 @@ -90,14 +90,14 @@ (defun make-socket-stream (socket acceptor) "Returns a stream for the socket SOCKET. The ACCEPTOR argument is used to set the timeouts."
- #-:lispworks5
- #+:lispworks4
(when (acceptor-write-timeout acceptor) (parameter-error "You need LispWorks 5 or higher for write timeouts.")) (make-instance 'comm:socket-stream :socket socket :direction :io :read-timeout (acceptor-read-timeout acceptor)
- #+:lispworks5 #+:lispworks5
- #-:lispworks4
:write-timeout (acceptor-write-timeout acceptor) :element-type 'octet))
Edi Weitz edi@agharta.de writes:
On Thu, Oct 1, 2009 at 1:04 AM, Hans Hübner hans.huebner@gmail.com wrote:
The patch does not look as if it worked for the Lispworks 4 case.
LW4 didn't have write timeouts (and, yes, I think some people still use it).
Yes.
I guess Nico wanted to have #- instead of #+ in there,
No, it is as intended. Please correct me if I am having a brain fart.
but I think it's safer, although a bit more clumsy, to specifically mention LW5 and LW6 (which, as we know from the ECLM, will be released soon).
The first patch I sent to Edi privately, was as the one at the bottom. But isn't
#+:lispworks4 == #-(or :lispworks5 :lispworks6) and #-:lispworks4 == #+(or :lispworks5 :lispworks6)
when we are only considering version 4, 5 and 6? In fact, the patch at the top is better, since when LispWorks 7.x comes out the patch above will already work as it covers versions 4 and higher, but the patch below will have to be amended, since it only covers version 4, 5 and 6. Which one is clearer, is subjective - I like the one at the top because the exceptions is specifically for LispWorks4 and for the reason described in the previous sentence.
B.t.w. the double #+:lispworks5 #+:lispworks5 in the original code is a (harmless) mistake, correct?
Regards. Nico
$ diff -u lispworks.lisp_orig lispworks.lisp_patched2 --- lispworks.lisp_orig 2009-09-30 11:42:22.000000000 +0200 +++ lispworks.lisp_patched2 2009-10-01 18:58:19.102193637 +0200 @@ -90,14 +90,14 @@ (defun make-socket-stream (socket acceptor) "Returns a stream for the socket SOCKET. The ACCEPTOR argument is used to set the timeouts." - #-:lispworks5 + #-(or :lispworks5 :lispworks6) (when (acceptor-write-timeout acceptor) (parameter-error "You need LispWorks 5 or higher for write timeouts.")) (make-instance 'comm:socket-stream :socket socket :direction :io :read-timeout (acceptor-read-timeout acceptor) - #+:lispworks5 #+:lispworks5 + #+(or :lispworks5 :lispworks6) :write-timeout (acceptor-write-timeout acceptor) :element-type 'octet))
On Thu, Oct 1, 2009 at 8:49 PM, Nico de Jager ndj@bitart.cc wrote:
No, it is as intended. Please correct me if I am having a brain fart.
My bad. I didn't look closely enough.
The first patch I sent to Edi privately, was as the one at the bottom. But isn't
#+:lispworks4 == #-(or :lispworks5 :lispworks6) and #-:lispworks4 == #+(or :lispworks5 :lispworks6)
when we are only considering version 4, 5 and 6? In fact, the patch at the top is better, since when LispWorks 7.x comes out the patch above will already work as it covers versions 4 and higher, but the patch below will have to be amended, since it only covers version 4, 5 and 6. Which one is clearer, is subjective - I like the one at the top because the exceptions is specifically for LispWorks4 and for the reason described in the previous sentence.
What I don't like about this is that it doesn't take LW3 into account... :)
Only half joking, really. Starting with LW4 seems a rather arbitrary assumption to me although the code very likely won't work with LW3 anyway, but the code isn't self-documenting anymore. #-:lispworks4 says "for all except LW4" while you actually wanted to say "for LW5 and LW6 and maybe LW7 as well".
B.t.w. the double #+:lispworks5 #+:lispworks5 in the original code is a (harmless) mistake, correct?
No, it's on purpose. It affects the /two/ forms following it and your patch must also take care of two forms.
Thanks, Edi.
Edi Weitz edi@agharta.de writes:
On Thu, Oct 1, 2009 at 8:49 PM, Nico de Jager ndj@bitart.cc wrote:
No, it is as intended. Please correct me if I am having a brain fart.
My bad. I didn't look closely enough.
The first patch I sent to Edi privately, was as the one at the bottom. But isn't
#+:lispworks4 == #-(or :lispworks5 :lispworks6) and #-:lispworks4 == #+(or :lispworks5 :lispworks6)
when we are only considering version 4, 5 and 6? In fact, the patch at the top is better, since when LispWorks 7.x comes out the patch above will already work as it covers versions 4 and higher, but the patch below will have to be amended, since it only covers version 4, 5 and 6. Which one is clearer, is subjective - I like the one at the top because the exceptions is specifically for LispWorks4 and for the reason described in the previous sentence.
What I don't like about this is that it doesn't take LW3 into account... :)
Only half joking, really. Starting with LW4 seems a rather arbitrary assumption to me although the code very likely won't work with LW3 anyway, but the code isn't self-documenting anymore. #-:lispworks4 says "for all except LW4" while you actually wanted to say "for LW5 and LW6 and maybe LW7 as well".
But..., hmm..., ok. :-)
B.t.w. the double #+:lispworks5 #+:lispworks5 in the original code is a (harmless) mistake, correct?
No, it's on purpose. It affects the /two/ forms following it and your patch must also take care of two forms.
I see - thanks Edi. Back to the CLHS then...
Below, is another attempt.
Regards. Nico
$ diff -u lispworks.lisp lispworks.lisp_patched3 --- lispworks.lisp 2009-02-17 00:14:24.000000000 +0200 +++ lispworks.lisp_patched3 2009-10-02 20:03:58.986727798 +0200 @@ -90,14 +90,14 @@ (defun make-socket-stream (socket acceptor) "Returns a stream for the socket SOCKET. The ACCEPTOR argument is used to set the timeouts." - #-:lispworks5 + #-(or :lispworks5 :lispworks6) (when (acceptor-write-timeout acceptor) (parameter-error "You need LispWorks 5 or higher for write timeouts.")) (make-instance 'comm:socket-stream :socket socket :direction :io :read-timeout (acceptor-read-timeout acceptor) - #+:lispworks5 #+:lispworks5 + #+(or :lispworks5 :lispworks6) #+(or :lispworks5 :lispworks6) :write-timeout (acceptor-write-timeout acceptor) :element-type 'octet))
Thanks, applied to the dev version.
Edi.
On Fri, Oct 2, 2009 at 8:05 PM, Nico de Jager ndj@bitart.cc wrote:
Edi Weitz edi@agharta.de writes:
On Thu, Oct 1, 2009 at 8:49 PM, Nico de Jager ndj@bitart.cc wrote:
No, it is as intended. Please correct me if I am having a brain fart.
My bad. I didn't look closely enough.
The first patch I sent to Edi privately, was as the one at the bottom. But isn't
#+:lispworks4 == #-(or :lispworks5 :lispworks6) and #-:lispworks4 == #+(or :lispworks5 :lispworks6)
when we are only considering version 4, 5 and 6? In fact, the patch at the top is better, since when LispWorks 7.x comes out the patch above will already work as it covers versions 4 and higher, but the patch below will have to be amended, since it only covers version 4, 5 and 6. Which one is clearer, is subjective - I like the one at the top because the exceptions is specifically for LispWorks4 and for the reason described in the previous sentence.
What I don't like about this is that it doesn't take LW3 into account... :)
Only half joking, really. Starting with LW4 seems a rather arbitrary assumption to me although the code very likely won't work with LW3 anyway, but the code isn't self-documenting anymore. #-:lispworks4 says "for all except LW4" while you actually wanted to say "for LW5 and LW6 and maybe LW7 as well".
But..., hmm..., ok. :-)
B.t.w. the double #+:lispworks5 #+:lispworks5 in the original code is a (harmless) mistake, correct?
No, it's on purpose. It affects the /two/ forms following it and your patch must also take care of two forms.
I see - thanks Edi. Back to the CLHS then...
Below, is another attempt.
Regards. Nico
$ diff -u lispworks.lisp lispworks.lisp_patched3 --- lispworks.lisp 2009-02-17 00:14:24.000000000 +0200 +++ lispworks.lisp_patched3 2009-10-02 20:03:58.986727798 +0200 @@ -90,14 +90,14 @@ (defun make-socket-stream (socket acceptor) "Returns a stream for the socket SOCKET. The ACCEPTOR argument is used to set the timeouts."
- #-:lispworks5
- #-(or :lispworks5 :lispworks6)
(when (acceptor-write-timeout acceptor) (parameter-error "You need LispWorks 5 or higher for write timeouts.")) (make-instance 'comm:socket-stream :socket socket :direction :io :read-timeout (acceptor-read-timeout acceptor)
- #+:lispworks5 #+:lispworks5
- #+(or :lispworks5 :lispworks6) #+(or :lispworks5 :lispworks6)
:write-timeout (acceptor-write-timeout acceptor) :element-type 'octet))
tbnl-devel site list tbnl-devel@common-lisp.net http://common-lisp.net/mailman/listinfo/tbnl-devel