[REBOL] Problem with try [ open/direct/binary tcp://... ] Re:(8)
From: joel:neely:fedex at: 3-Oct-2000 8:57
Just a brief follow-up after checking the new docs...
[...code samples snipped...]
> INSERT shouldn't use FORM when inserting a BINARY!. I'm sending
> this to feedback too (I don't remember if I had already signaled
> this to feedback...).
Page 7-3 (225 of 574) begins by saying
This chapter will introduce functions that convert REBOL values
into strings. These functions are used often ... They include:
followed by Table 7-2, titled "String Conversion Functions". In
that table join is described as "convert values with no spaces".
Later on, page 7-4 (226 of 574) states:
The join function takes two arguments and concatenates
them into a single series.
The data type of series returned is based on the value of the
first argument. When the first argument is a series value,
that series type is returned.
and then proceeds to give examples of computing string! , file! ,
and url! values via join invocations.
The next page goes on to say:
When the first argument is not a series, the join converts
it to a string first, then performs the append.
Finally the following page (7-6, 228 of 574) says
When the second argument to join is a block, the values of
that block are evaluated and appended to the series returned.
This is not a smack-in-the-kisser blunt as I would like, but I
think it means this (*WARNING* *MY NON-OFFICIAL READING*):
Type of Type of Type of
1st arg 2nd arg result Treatment of args
----------- ----------- ----------- --------------------------
1) any-string! not block! arg 1 type arg 2 value converted to
string and appended to
copy of arg 1 value
2) any-string! any-block! arg 1 type arg 2 values converted to
strings and appended to
copy of arg 1 value
any-string! any string! join to-string arg1 arg2
(now guaranteed to be one
of the first two cases)
If I'm correct, the behavior with a binary! first argument is
actually the intended, documented behavior, as the binary! type
is subsumed under the any-string! type.
P.S. "I'm not a language lawyer, but I play one on the 'Net!" ;-)
Isn't it fun having a spec?!?!