Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
92e31944
Commit
92e31944
authored
Feb 27, 1998
by
Fred Drake
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Deprecate the read() and write() methods.
Don't refer to them from the fromfile() and tofile() methods.
parent
26c73b78
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
16 deletions
+8
-16
Doc/lib/libarray.tex
Doc/lib/libarray.tex
+4
-8
Doc/libarray.tex
Doc/libarray.tex
+4
-8
No files found.
Doc/lib/libarray.tex
View file @
92e31944
...
@@ -84,8 +84,6 @@ are available, \exception{EOFError} is raised, but the items that were
...
@@ -84,8 +84,6 @@ are available, \exception{EOFError} is raised, but the items that were
available are still inserted into the array.
\var
{
f
}
must be a real
available are still inserted into the array.
\var
{
f
}
must be a real
built-in file object; something else with a
\code
{
read()
}
method won't
built-in file object; something else with a
\code
{
read()
}
method won't
do.
do.
Also available as the
\method
{
read()
}
method.
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
fromlist
}{
list
}
\begin{funcdesc}
{
fromlist
}{
list
}
...
@@ -106,14 +104,14 @@ Insert a new item with value \var{x} in the array before position
...
@@ -106,14 +104,14 @@ Insert a new item with value \var{x} in the array before position
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
read
}{
f
\,
n
}
\begin{funcdesc}
{
read
}{
f
\,
n
}
\deprecated
{
1.5.1
}
{
Use the
\method
{
fromfile()
}
method.
}
Read
\var
{
n
}
items (as machine values) from the file object
\var
{
f
}
Read
\var
{
n
}
items (as machine values) from the file object
\var
{
f
}
and append them to the end of the array. If less than
\var
{
n
}
items
and append them to the end of the array. If less than
\var
{
n
}
items
are available,
\exception
{
EOFError
}
is raised, but the items that were
are available,
\exception
{
EOFError
}
is raised, but the items that were
available are still inserted into the array.
\var
{
f
}
must be a real
available are still inserted into the array.
\var
{
f
}
must be a real
built-in file object; something else with a
\method
{
read()
}
method won't
built-in file object; something else with a
\method
{
read()
}
method won't
do.
do.
Also available as the
\method
{
fromfile()
}
method.
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
reverse
}{}
\begin{funcdesc}
{
reverse
}{}
...
@@ -122,8 +120,6 @@ Reverse the order of the items in the array.
...
@@ -122,8 +120,6 @@ Reverse the order of the items in the array.
\begin{funcdesc}
{
tofile
}{
f
}
\begin{funcdesc}
{
tofile
}{
f
}
Write all items (as machine values) to the file object
\var
{
f
}
.
Write all items (as machine values) to the file object
\var
{
f
}
.
Also available as the
\function
{
write()
}
function.
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
tolist
}{}
\begin{funcdesc}
{
tolist
}{}
...
@@ -137,9 +133,9 @@ be written to a file by the \method{tofile()} method.)
...
@@ -137,9 +133,9 @@ be written to a file by the \method{tofile()} method.)
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
write
}{
f
}
\begin{funcdesc}
{
write
}{
f
}
\deprecated
{
1.5.1
}
{
Use the
\method
{
tofile()
}
method.
}
Write all items (as machine values) to the file object
\var
{
f
}
.
Write all items (as machine values) to the file object
\var
{
f
}
.
Also available as the
\function
{
write()
}
function.
\end{funcdesc}
\end{funcdesc}
When an array object is printed or converted to a string, it is
When an array object is printed or converted to a string, it is
...
...
Doc/libarray.tex
View file @
92e31944
...
@@ -84,8 +84,6 @@ are available, \exception{EOFError} is raised, but the items that were
...
@@ -84,8 +84,6 @@ are available, \exception{EOFError} is raised, but the items that were
available are still inserted into the array.
\var
{
f
}
must be a real
available are still inserted into the array.
\var
{
f
}
must be a real
built-in file object; something else with a
\code
{
read()
}
method won't
built-in file object; something else with a
\code
{
read()
}
method won't
do.
do.
Also available as the
\method
{
read()
}
method.
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
fromlist
}{
list
}
\begin{funcdesc}
{
fromlist
}{
list
}
...
@@ -106,14 +104,14 @@ Insert a new item with value \var{x} in the array before position
...
@@ -106,14 +104,14 @@ Insert a new item with value \var{x} in the array before position
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
read
}{
f
\,
n
}
\begin{funcdesc}
{
read
}{
f
\,
n
}
\deprecated
{
1.5.1
}
{
Use the
\method
{
fromfile()
}
method.
}
Read
\var
{
n
}
items (as machine values) from the file object
\var
{
f
}
Read
\var
{
n
}
items (as machine values) from the file object
\var
{
f
}
and append them to the end of the array. If less than
\var
{
n
}
items
and append them to the end of the array. If less than
\var
{
n
}
items
are available,
\exception
{
EOFError
}
is raised, but the items that were
are available,
\exception
{
EOFError
}
is raised, but the items that were
available are still inserted into the array.
\var
{
f
}
must be a real
available are still inserted into the array.
\var
{
f
}
must be a real
built-in file object; something else with a
\method
{
read()
}
method won't
built-in file object; something else with a
\method
{
read()
}
method won't
do.
do.
Also available as the
\method
{
fromfile()
}
method.
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
reverse
}{}
\begin{funcdesc}
{
reverse
}{}
...
@@ -122,8 +120,6 @@ Reverse the order of the items in the array.
...
@@ -122,8 +120,6 @@ Reverse the order of the items in the array.
\begin{funcdesc}
{
tofile
}{
f
}
\begin{funcdesc}
{
tofile
}{
f
}
Write all items (as machine values) to the file object
\var
{
f
}
.
Write all items (as machine values) to the file object
\var
{
f
}
.
Also available as the
\function
{
write()
}
function.
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
tolist
}{}
\begin{funcdesc}
{
tolist
}{}
...
@@ -137,9 +133,9 @@ be written to a file by the \method{tofile()} method.)
...
@@ -137,9 +133,9 @@ be written to a file by the \method{tofile()} method.)
\end{funcdesc}
\end{funcdesc}
\begin{funcdesc}
{
write
}{
f
}
\begin{funcdesc}
{
write
}{
f
}
\deprecated
{
1.5.1
}
{
Use the
\method
{
tofile()
}
method.
}
Write all items (as machine values) to the file object
\var
{
f
}
.
Write all items (as machine values) to the file object
\var
{
f
}
.
Also available as the
\function
{
write()
}
function.
\end{funcdesc}
\end{funcdesc}
When an array object is printed or converted to a string, it is
When an array object is printed or converted to a string, it is
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment