David W. Lambert
<lambertdw@corning.com> added the comment:
I disagree. You propose to examine the trees but ignore the
forest.
The perspective programmer needs to
understand what is a file.
Could you be more specific about what parts of my comments you
disagree with? The current documentation leaves open the possibility
of someone thinking that random access doesn't apply to text files,
getting errors when entering the apparently legal, but in reality not,
'b', and that '+', 't+', and 'b+' are legal whereas they require a r,
w, or a.
I know this bit of documentation has been stable for years, but
in doing some writing I got tripped up by trying to write an example
using just '+', despite being very knowledgeable about Python. At that
pointI experimented with the various combinations and compared the
reality against the documentation. What I ended up doing is splitting
the table in two and listing the + combinations explicitly:
Text or Binary:
t
text
b
binary
Read, Write, or Append:
r
beginning, read
w
beginning, write
a end,
write
r+ beginning,
read/write
w+ beginning,
read/write
a+ end,
read/write
--
--- Mitchell