| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 314464d commit 7462b64
86 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -40,7 +40,7 @@ protocol <bufferobjects>`. This protocol has two sides: | |||
| 40 | 40 | ||
| 41 | 41 | Simple objects such as :class:`bytes` and :class:`bytearray` expose their | |
| 42 | 42 | underlying buffer in byte-oriented form. Other forms are possible; for example, | |
| 43 | - the elements exposed by a :class:`array.array` can be multi-byte values. | ||
| 43 | + the elements exposed by an :class:`array.array` can be multi-byte values. | ||
| 44 | 44 | ||
| 45 | 45 | An example consumer of the buffer interface is the :meth:`~io.BufferedIOBase.write` | |
| 46 | 46 | method of file objects: any object that can export a series of bytes through | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -849,7 +849,7 @@ How do I modify a string in place? | |||
| 849 | 849 | You can't, because strings are immutable. In most situations, you should | |
| 850 | 850 | simply construct a new string from the various parts you want to assemble | |
| 851 | 851 | it from. However, if you need an object with the ability to modify in-place | |
| 852 | - unicode data, try using a :class:`io.StringIO` object or the :mod:`array` | ||
| 852 | + unicode data, try using an :class:`io.StringIO` object or the :mod:`array` | ||
| 853 | 853 | module:: | |
| 854 | 854 | ||
| 855 | 855 | >>> import io | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -47,7 +47,7 @@ Usually an IFF-type file consists of one or more chunks. The proposed usage of | |||
| 47 | 47 | the :class:`Chunk` class defined here is to instantiate an instance at the start | |
| 48 | 48 | of each chunk and read from the instance until it reaches the end, after which a | |
| 49 | 49 | new instance can be instantiated. At the end of the file, creating a new | |
| 50 | - instance will fail with a :exc:`EOFError` exception. | ||
| 50 | + instance will fail with an :exc:`EOFError` exception. | ||
| 51 | 51 | ||
| 52 | 52 | ||
| 53 | 53 | .. class:: Chunk(file, align=True, bigendian=True, inclheader=False) | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -81,7 +81,7 @@ Executor Objects | |||
| 81 | 81 | ThreadPoolExecutor | |
| 82 | 82 | ------------------ | |
| 83 | 83 | ||
| 84 | - :class:`ThreadPoolExecutor` is a :class:`Executor` subclass that uses a pool of | ||
| 84 | + :class:`ThreadPoolExecutor` is an :class:`Executor` subclass that uses a pool of | ||
| 85 | 85 | threads to execute calls asynchronously. | |
| 86 | 86 | ||
| 87 | 87 | Deadlocks can occur when the callable associated with a :class:`Future` waits on | |
@@ -285,7 +285,7 @@ The :class:`Future` class encapsulates the asynchronous execution of a callable. | |||
| 285 | 285 | ||
| 286 | 286 | Added callables are called in the order that they were added and are | |
| 287 | 287 | always called in a thread belonging to the process that added them. If | |
| 288 | - the callable raises a :exc:`Exception` subclass, it will be logged and | ||
| 288 | + the callable raises an :exc:`Exception` subclass, it will be logged and | ||
| 289 | 289 | ignored. If the callable raises a :exc:`BaseException` subclass, the | |
| 290 | 290 | behavior is undefined. | |
| 291 | 291 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -39,7 +39,7 @@ loads libraries which export functions using the standard ``cdecl`` calling | |||
| 39 | 39 | convention, while *windll* libraries call functions using the ``stdcall`` | |
| 40 | 40 | calling convention. *oledll* also uses the ``stdcall`` calling convention, and | |
| 41 | 41 | assumes the functions return a Windows :c:type:`HRESULT` error code. The error | |
| 42 | - code is used to automatically raise a :class:`OSError` exception when the | ||
| 42 | + code is used to automatically raise an :class:`OSError` exception when the | ||
| 43 | 43 | function call fails. | |
| 44 | 44 | ||
| 45 | 45 | .. versionchanged:: 3.3 | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -269,7 +269,7 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module. | |||
| 269 | 269 | generating the delta lines) in unified diff format. | |
| 270 | 270 | ||
| 271 | 271 | Unified diffs are a compact way of showing just the lines that have changed plus | |
| 272 | - a few lines of context. The changes are shown in a inline style (instead of | ||
| 272 | + a few lines of context. The changes are shown in an inline style (instead of | ||
| 273 | 273 | separate before/after blocks). The number of context lines is set by *n* which | |
| 274 | 274 | defaults to three. | |
| 275 | 275 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -16,13 +16,13 @@ interface to the :c:func:`fcntl` and :c:func:`ioctl` Unix routines. | |||
| 16 | 16 | ||
| 17 | 17 | All functions in this module take a file descriptor *fd* as their first | |
| 18 | 18 | argument. This can be an integer file descriptor, such as returned by | |
| 19 | - ``sys.stdin.fileno()``, or a :class:`io.IOBase` object, such as ``sys.stdin`` | ||
| 19 | + ``sys.stdin.fileno()``, or an :class:`io.IOBase` object, such as ``sys.stdin`` | ||
| 20 | 20 | itself, which provides a :meth:`~io.IOBase.fileno` that returns a genuine file | |
| 21 | 21 | descriptor. | |
| 22 | 22 | ||
| 23 | 23 | .. versionchanged:: 3.3 | |
| 24 | - Operations in this module used to raise a :exc:`IOError` where they now | ||
| 25 | - raise a :exc:`OSError`. | ||
| 24 | + Operations in this module used to raise an :exc:`IOError` where they now | ||
| 25 | + raise an :exc:`OSError`. | ||
| 26 | 26 | ||
| 27 | 27 | ||
| 28 | 28 | The module defines the following functions: | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -287,9 +287,9 @@ followed by ``lines`` for the text version or ``binary`` for the binary version. | |||
| 287 | 287 | ||
| 288 | 288 | .. method:: FTP.transfercmd(cmd, rest=None) | |
| 289 | 289 | ||
| 290 | - Initiate a transfer over the data connection. If the transfer is active, send a | ||
| 290 | + Initiate a transfer over the data connection. If the transfer is active, send an | ||
| 291 | 291 | ``EPRT`` or ``PORT`` command and the transfer command specified by *cmd*, and | |
| 292 | - accept the connection. If the server is passive, send a ``EPSV`` or ``PASV`` | ||
| 292 | + accept the connection. If the server is passive, send an ``EPSV`` or ``PASV`` | ||
| 293 | 293 | command, connect to it, and start the transfer command. Either way, return the | |
| 294 | 294 | socket for the connection. | |
| 295 | 295 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1029,9 +1029,9 @@ are always available. They are listed here in alphabetical order. | |||
| 1029 | 1029 | :class:`io.TextIOBase` (specifically :class:`io.TextIOWrapper`). When used | |
| 1030 | 1030 | to open a file in a binary mode with buffering, the returned class is a | |
| 1031 | 1031 | subclass of :class:`io.BufferedIOBase`. The exact class varies: in read | |
| 1032 | - binary mode, it returns a :class:`io.BufferedReader`; in write binary and | ||
| 1033 | - append binary modes, it returns a :class:`io.BufferedWriter`, and in | ||
| 1034 | - read/write mode, it returns a :class:`io.BufferedRandom`. When buffering is | ||
| 1032 | + binary mode, it returns an :class:`io.BufferedReader`; in write binary and | ||
| 1033 | + append binary modes, it returns an :class:`io.BufferedWriter`, and in | ||
| 1034 | + read/write mode, it returns an :class:`io.BufferedRandom`. When buffering is | ||
| 1035 | 1035 | disabled, the raw stream, a subclass of :class:`io.RawIOBase`, | |
| 1036 | 1036 | :class:`io.FileIO`, is returned. | |
| 1037 | 1037 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -100,7 +100,7 @@ The module defines the following items: | |||
| 100 | 100 | ||
| 101 | 101 | Calling a :class:`GzipFile` object's :meth:`close` method does not close | |
| 102 | 102 | *fileobj*, since you might wish to append more material after the compressed | |
| 103 | - data. This also allows you to pass a :class:`io.BytesIO` object opened for | ||
| 103 | + data. This also allows you to pass an :class:`io.BytesIO` object opened for | ||
| 104 | 104 | writing as *fileobj*, and retrieve the resulting memory buffer using the | |
| 105 | 105 | :class:`io.BytesIO` object's :meth:`~io.BytesIO.getvalue` method. | |
| 106 | 106 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments