summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorHynek Schlawack <hs@ox.cx>2012-05-21 09:01:54 (GMT)
committerHynek Schlawack <hs@ox.cx>2012-05-21 09:01:54 (GMT)
commitdfa465243c94b540099c413eb79b2774b40bb82e (patch)
tree3b67d5600dc9fa2be8843c024259336d73e69b1e /Doc/library
parentf54c0604c852c2bf0b4d522cea7d94f205a795e8 (diff)
downloadcpython-dfa465243c94b540099c413eb79b2774b40bb82e.zip
cpython-dfa465243c94b540099c413eb79b2774b40bb82e.tar.gz
cpython-dfa465243c94b540099c413eb79b2774b40bb82e.tar.bz2
#14804: Remove [] around optional arguments with default values
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/curses.rst2
-rw-r--r--Doc/library/email.generator.rst2
-rw-r--r--Doc/library/http.cookiejar.rst2
-rw-r--r--Doc/library/nis.rst6
-rw-r--r--Doc/library/os.rst2
-rw-r--r--Doc/library/ossaudiodev.rst2
-rw-r--r--Doc/library/select.rst4
-rw-r--r--Doc/library/sqlite3.rst2
8 files changed, 11 insertions, 11 deletions
diff --git a/Doc/library/curses.rst b/Doc/library/curses.rst
index f31b9c5..0b8b7c9 100644
--- a/Doc/library/curses.rst
+++ b/Doc/library/curses.rst
@@ -1091,7 +1091,7 @@ the following methods:
rendition (as set by :meth:`bkgdset`) merged into them.
-.. method:: window.scroll([lines=1])
+.. method:: window.scroll(lines=1)
Scroll the screen or scrolling region upward by *lines* lines.
diff --git a/Doc/library/email.generator.rst b/Doc/library/email.generator.rst
index f40869c..3be04a2 100644
--- a/Doc/library/email.generator.rst
+++ b/Doc/library/email.generator.rst
@@ -178,7 +178,7 @@ except that non-\ :mimetype:`text` parts are substituted with a format string
representing the part.
-.. class:: DecodedGenerator(outfp[, mangle_from_=True, maxheaderlen=78, fmt=None)
+.. class:: DecodedGenerator(outfp, mangle_from_=True, maxheaderlen=78, fmt=None)
This class, derived from :class:`Generator` walks through all the subparts of a
message. If the subpart is of main type :mimetype:`text`, then it prints the
diff --git a/Doc/library/http.cookiejar.rst b/Doc/library/http.cookiejar.rst
index 9771496..cc8f251 100644
--- a/Doc/library/http.cookiejar.rst
+++ b/Doc/library/http.cookiejar.rst
@@ -700,7 +700,7 @@ accessed using the following methods:
The :class:`Cookie` class also defines the following method:
-.. method:: Cookie.is_expired([now=None])
+.. method:: Cookie.is_expired(now=None)
True if cookie has passed the time at which the server requested it should
expire. If *now* is given (in seconds since the epoch), return whether the
diff --git a/Doc/library/nis.rst b/Doc/library/nis.rst
index 1281e3f..ade2a7a 100644
--- a/Doc/library/nis.rst
+++ b/Doc/library/nis.rst
@@ -17,7 +17,7 @@ Because NIS exists only on Unix systems, this module is only available for Unix.
The :mod:`nis` module defines the following functions:
-.. function:: match(key, mapname[, domain=default_domain])
+.. function:: match(key, mapname, domain=default_domain)
Return the match for *key* in map *mapname*, or raise an error
(:exc:`nis.error`) if there is none. Both should be strings, *key* is 8-bit
@@ -30,7 +30,7 @@ The :mod:`nis` module defines the following functions:
unspecified, lookup is in the default NIS domain.
-.. function:: cat(mapname[, domain=default_domain])
+.. function:: cat(mapname, domain=default_domain)
Return a dictionary mapping *key* to *value* such that ``match(key,
mapname)==value``. Note that both keys and values of the dictionary are
@@ -42,7 +42,7 @@ The :mod:`nis` module defines the following functions:
unspecified, lookup is in the default NIS domain.
-.. function:: maps([domain=default_domain])
+.. function:: maps(domain=default_domain)
Return a list of all valid maps.
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
index 0b66d2b..8b2e582 100644
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -1145,7 +1145,7 @@ Files and Directories
Availability: Unix.
-.. function:: mknod(filename[, mode=0o600[, device]])
+.. function:: mknod(filename, mode=0o600, device=0)
Create a filesystem node (file, device special file or named pipe) named
*filename*. *mode* specifies both the permissions to use and the type of node
diff --git a/Doc/library/ossaudiodev.rst b/Doc/library/ossaudiodev.rst
index 0a08428..fbbda26 100644
--- a/Doc/library/ossaudiodev.rst
+++ b/Doc/library/ossaudiodev.rst
@@ -277,7 +277,7 @@ The following convenience methods combine several ioctls, or one ioctl and some
simple calculations.
-.. method:: oss_audio_device.setparameters(format, nchannels, samplerate [, strict=False])
+.. method:: oss_audio_device.setparameters(format, nchannels, samplerate, strict=False)
Set the key audio sampling parameters---sample format, number of channels, and
sampling rate---in one method call. *format*, *nchannels*, and *samplerate*
diff --git a/Doc/library/select.rst b/Doc/library/select.rst
index f1fd126..6f8df6e 100644
--- a/Doc/library/select.rst
+++ b/Doc/library/select.rst
@@ -181,7 +181,7 @@ Edge and Level Trigger Polling (epoll) Objects
Remove a registered file descriptor from the epoll object.
-.. method:: epoll.poll([timeout=-1[, maxevents=-1]])
+.. method:: epoll.poll(timeout=-1, maxevents=-1)
Wait for events. timeout in seconds (float)
@@ -285,7 +285,7 @@ Kqueue Objects
Create a kqueue object from a given file descriptor.
-.. method:: kqueue.control(changelist, max_events[, timeout=None]) -> eventlist
+.. method:: kqueue.control(changelist, max_events, timeout=None) -> eventlist
Low level interface to kevent
diff --git a/Doc/library/sqlite3.rst b/Doc/library/sqlite3.rst
index 41db5c3..babbfa5 100644
--- a/Doc/library/sqlite3.rst
+++ b/Doc/library/sqlite3.rst
@@ -514,7 +514,7 @@ Cursor Objects
or :const:`None` when no more data is available.
-.. method:: Cursor.fetchmany([size=cursor.arraysize])
+.. method:: Cursor.fetchmany(size=cursor.arraysize)
Fetches the next set of rows of a query result, returning a list. An empty
list is returned when no more rows are available.