]> granicus.if.org Git - python/commitdiff
Note that open() is the preferred way to open files (issue 1510).
authorSkip Montanaro <skip@pobox.com>
Sat, 8 Dec 2007 14:37:43 +0000 (14:37 +0000)
committerSkip Montanaro <skip@pobox.com>
Sat, 8 Dec 2007 14:37:43 +0000 (14:37 +0000)
Objects/fileobject.c
Python/bltinmodule.c

index 271f4cdc55a613eaf77aff3d168960dc106ae5d7..4dd5c712b79fd5256a219b66641abac2d9c1dc38 100644 (file)
@@ -2065,7 +2065,8 @@ PyDoc_STR(
 "opened for writing.  Add a 'b' to the mode for binary files.\n"
 "Add a '+' to the mode to allow simultaneous reading and writing.\n"
 "If the buffering argument is given, 0 means unbuffered, 1 means line\n"
-"buffered, and larger numbers specify the buffer size.\n"
+"buffered, and larger numbers specify the buffer size.  The preferred way\n"
+"to open a file is with the builtin open() function.\n"
 )
 PyDoc_STR(
 "Add a 'U' to mode to open the file for input with universal newline\n"
index e1242fdede475489623fa1ee8b313e6a903504eb..92304b3862ea97b927d94725fa4b281f09cfc88a 100644 (file)
@@ -1357,7 +1357,8 @@ builtin_open(PyObject *self, PyObject *args, PyObject *kwds)
 PyDoc_STRVAR(open_doc,
 "open(name[, mode[, buffering]]) -> file object\n\
 \n\
-Open a file using the file() type, returns a file object.");
+Open a file using the file() type, returns a file object.  This is the\n\
+preferred way to open a file.");
 
 
 static PyObject *