Alexey Radul scripsit:
> In reading through Draft 9 for acceptability, I came across a number
> of little mistakes and confusions that we should correct. A handful
> are just plain typos, and there are a few places where our text does
> not perfectly codify our intent or existing practice. All the changes
> needed to fix these issues seem to me to be purely editorial.
Thank you very much for this thorough review. I'm making all changes
on the draft-10 branch.
> - Typo [p.27]. The last example in the first block of examples of
> quasiquotation is missing the symbol "list" in the result.
Fixed.
> - I assume someone ran the library example program [pp.28-29] in Chibi
> and confirmed that it works as expected?
It actually doesn't work for me. Can someone else try it?
> - equal? of records [p.31] is implicitly unspecified. Should it be
> mentioned that it is explicitly unspecified, to prevent readers from
> assuming that records appear in one or the other of the lists of
> types that appear in the specification of equal?, or from having to
> do a double-take to notice that it is absent from both of them? Or
> was implicit unspecification an intentional choice that I have
> forgotten?
That's the purpose of the "in all other cases" clause. It allows
implementations to treat `eqv?` and `equal?` either differently or the
same on records. The idea is that (modulo circularity) implementations
should have to change their definition of `equal?` for R7RS compliance.
If existing code expects `equal?` to descend through records, fine;
if it expects `equal?` to be `eqv?` on records, fine; in either case
such code is not portable.
No change here.
> - Presentation of symbol identity [p.43]. Why do we describe symbol
> identity in terms of eqv? in the text, but use eq? in the examples?
Fixed to use eqv? in the examples.
> - Additional character names [p.44].
See separate posting.
> - Character comparison [p.44]. This section is written assuming that
> an implementation only supports a subset of Unicode, and is a bit
> hard to interpret for non-Unicode characters.
I have rewritten this as "These procedures return #t if the results
of passing their arguments to char->integer are respectively equal,
monotonically increasing, monotonically decreasing, monotonically
non-decreasing, or monotonically non-increasing." This wording defers to
the definition of `char->integer`, which specifies that all non-Unicode
characters correspond to integers greater than any Unicode scalar value.
> - Stylistic uniformity on characters forbidden from strings [pp.45-47]
> We list make-string, string, string-set!, and string-fill! but not
> list->string as procedures to which it is an error to pass
> characters that are forbidden in strings.
Fixed.
> In the specification of string-fill! but not the others we repeat
> the injunction against forbidden characters. I think we should
> either include that injunction everywhere it applies or nowhere.
Added everywhere.
> - The same comment applies to vector->string [p.48], but with even
> greater force because it is farther away from the discussion of
> strings.
Already in place, but added this to the list in 6.7 with a
cross-reference.
> - It should also be an error if the procedure passed to string-map
> [p.50] returns a character that is forbidden in strings. This one
> we probably should mention explicitly.
> - The same comment applies to read-string [p.57] because read-char
> can in principle produce a character that is forbidden in strings.
Added (these are not domain errors) and added to the list as well.
Finally, I have added utf8->string to the list as well.
> - Typo [p.47]. string-copy! should copy to a *string* to (not a
> bytevector).
Fixed.
> - Grammar [pp.47,49]. "[example vector] can be written as *follows*:"
> - Same problem for the example bytevector on p.49.
Fixed.
> - Do map and friends [pp.50-51] always return newly allocated results?
See separate posting.
> - Newly allocated empty objects [pp.41-50]. [...]
> Probably the easiest way to fix this is to add a clause somewhere in
> the storage model section explicitly exempting empty objects from
> requirements of being newly allocated.
I rewrote the relevant passage thus:
Whenever this report speaks of storage being newly allocated for
a variable or object, what is meant is that an appropriate number
of locations are chosen from the set of locations that are not in
use, and the chosen locations are marked to indicate that they
are now in use before the variable or object is made to denote
them. Notwithstanding this, it is understood that the empty
list cannot be newly allocated, because it is a unique object.
It is also understood that empty strings, empty vectors, and
empty bytevectors, which contain no locations, may or may not
be newly allocated.
> We could also fix this by altering the wording of each allocating
> procedure so that it is not required to allocate a new result if it
> is empty.
Not going there, thanks. In any case, your list omits `(read-string 0)`
and `(read-bytevector 0)`, and perhaps other cases too.
--
Being understandable rather than obscurantist poses certain
risks, in that one's opinions are clear and therefore | John Cowan
falsifiable in the light of new data, but it has the |
co...@ccil.org
advantage of encouraging feedback from others. --James A. Matisoff