Skip to content

Commit 09b7503

Browse files
committed
Merge 3.2, Issue python#17047: remove doubled words found in 2.7 to 3.4
Modules/*, as reported by Serhiy Storchaka and Matthew Barnett.
2 parents caeb6be + 0158af3 commit 09b7503

File tree

10 files changed

+19
-19
lines changed

10 files changed

+19
-19
lines changed

Modules/_ctypes/callproc.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
2121
2. After several checks, _build_callargs() is called which returns another
2222
tuple 'callargs'. This may be the same tuple as 'inargs', a slice of
23-
'inargs', or a completely fresh tuple, depending on several things (is is a
24-
COM method, are 'paramflags' available).
23+
'inargs', or a completely fresh tuple, depending on several things (is it a
24+
COM method?, are 'paramflags' available?).
2525
2626
3. _build_callargs also calculates bitarrays containing indexes into
2727
the callargs tuple, specifying how to build the return value(s) of

Modules/_ctypes/libffi/src/dlmalloc.c

+6-6
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@
100100
101101
If you don't like either of these options, you can define
102102
CORRUPTION_ERROR_ACTION and USAGE_ERROR_ACTION to do anything
103-
else. And if if you are sure that your program using malloc has
103+
else. And if you are sure that your program using malloc has
104104
no errors or vulnerabilities, you can define INSECURE to 1,
105105
which might (or might not) provide a small performance improvement.
106106
@@ -607,7 +607,7 @@ DEFAULT_MMAP_THRESHOLD default: 256K
607607
declaration needed is the mallinfo struct that is returned (by-copy)
608608
by mallinfo(). The malloinfo struct contains a bunch of fields that
609609
are not even meaningful in this version of malloc. These fields are
610-
are instead filled by mallinfo() with other numbers that might be of
610+
instead filled by mallinfo() with other numbers that might be of
611611
interest.
612612
613613
HAVE_USR_INCLUDE_MALLOC_H should be set if you have a
@@ -1621,7 +1621,7 @@ static MLOCK_T magic_init_mutex;
16211621
Each freshly allocated chunk must have both cinuse and pinuse set.
16221622
That is, each allocated chunk borders either a previously allocated
16231623
and still in-use chunk, or the base of its memory arena. This is
1624-
ensured by making all allocations from the the `lowest' part of any
1624+
ensured by making all allocations from the `lowest' part of any
16251625
found chunk. Further, no free chunk physically borders another one,
16261626
so each free chunk is known to be preceded and followed by either
16271627
inuse chunks or the ends of memory.
@@ -1827,12 +1827,12 @@ nextchunk-> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
18271827
of the same size are arranged in a circularly-linked list, with only
18281828
the oldest chunk (the next to be used, in our FIFO ordering)
18291829
actually in the tree. (Tree members are distinguished by a non-null
1830-
parent pointer.) If a chunk with the same size an an existing node
1830+
parent pointer.) If a chunk with the same size as an existing node
18311831
is inserted, it is linked off the existing node using pointers that
18321832
work in the same way as fd/bk pointers of small chunks.
18331833
18341834
Each tree contains a power of 2 sized range of chunk sizes (the
1835-
smallest is 0x100 <= x < 0x180), which is is divided in half at each
1835+
smallest is 0x100 <= x < 0x180), which is divided in half at each
18361836
tree level, with the chunks in the smaller half of the range (0x100
18371837
<= x < 0x140 for the top nose) in the left subtree and the larger
18381838
half (0x140 <= x < 0x180) in the right subtree. This is, of course,
@@ -3442,7 +3442,7 @@ static void* sys_alloc(mstate m, size_t nb) {
34423442
least-preferred order):
34433443
1. A call to MORECORE that can normally contiguously extend memory.
34443444
(disabled if not MORECORE_CONTIGUOUS or not HAVE_MORECORE or
3445-
or main space is mmapped or a previous contiguous call failed)
3445+
main space is mmapped or a previous contiguous call failed)
34463446
2. A call to MMAP new space (disabled if not HAVE_MMAP).
34473447
Note that under the default settings, if MORECORE is unable to
34483448
fulfill a request, and HAVE_MMAP is true, then mmap is

Modules/_ctypes/libffi/src/ia64/ffi.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ endian_adjust (void *addr, size_t len)
8585
#define ldf_fill(result, addr) \
8686
asm ("ldf.fill %0 = %1%P1" : "=f"(result) : "m"(*addr));
8787

88-
/* Return the size of the C type associated with with TYPE. Which will
88+
/* Return the size of the C type associated with TYPE, which will
8989
be one of the FFI_IA64_TYPE_HFA_* values. */
9090

9191
static size_t
@@ -185,7 +185,7 @@ hfa_element_type (ffi_type *type, int nested)
185185
break;
186186

187187
case FFI_TYPE_LONGDOUBLE:
188-
/* Similarly, except that that HFA is true for double extended,
188+
/* Similarly, except that HFA is true for double extended,
189189
but not quad precision. Both have sizeof == 16, so tell the
190190
difference based on the precision. */
191191
if (LDBL_MANT_DIG == 64 && nested)

Modules/_heapqmodule.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ _siftup(PyListObject *heap, Py_ssize_t pos)
116116
}
117117
}
118118

119-
/* The leaf at pos is empty now. Put newitem there, and and bubble
119+
/* The leaf at pos is empty now. Put newitem there, and bubble
120120
it up to its final resting place (by sifting its parents down). */
121121
Py_DECREF(PyList_GET_ITEM(heap, pos));
122122
PyList_SET_ITEM(heap, pos, newitem);
@@ -456,7 +456,7 @@ _siftupmax(PyListObject *heap, Py_ssize_t pos)
456456
childpos = 2*pos + 1;
457457
}
458458

459-
/* The leaf at pos is empty now. Put newitem there, and and bubble
459+
/* The leaf at pos is empty now. Put newitem there, and bubble
460460
it up to its final resting place (by sifting its parents down). */
461461
Py_DECREF(PyList_GET_ITEM(heap, pos));
462462
PyList_SET_ITEM(heap, pos, newitem);

Modules/_io/iobase.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ iobase_unsupported(const char *message)
7676
PyDoc_STRVAR(iobase_seek_doc,
7777
"Change stream position.\n"
7878
"\n"
79-
"Change the stream position to byte offset offset. offset is\n"
79+
"Change the stream position to the given byte offset. The offset is\n"
8080
"interpreted relative to the position indicated by whence. Values\n"
8181
"for whence are:\n"
8282
"\n"

Modules/expat/xmltok.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1584,7 +1584,7 @@ initScan(const ENCODING * const *encodingTable,
15841584
if (ptr[0] == '\0') {
15851585
/* 0 isn't a legal data character. Furthermore a document
15861586
entity can only start with ASCII characters. So the only
1587-
way this can fail to be big-endian UTF-16 if it it's an
1587+
way this can fail to be big-endian UTF-16 is if it is an
15881588
external parsed general entity that's labelled as
15891589
UTF-16LE.
15901590
*/

Modules/ossaudiodev.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,7 @@ static int _is_fd_valid(int fd)
230230
}
231231

232232
/* _do_ioctl_1() is a private helper function used for the OSS ioctls --
233-
SNDCTL_DSP_{SETFMT,CHANNELS,SPEED} -- that that are called from C
233+
SNDCTL_DSP_{SETFMT,CHANNELS,SPEED} -- that are called from C
234234
like this:
235235
ioctl(fd, SNDCTL_DSP_cmd, &arg)
236236

Modules/zlib/deflate.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ struct static_tree_desc_s {int dummy;}; /* for buggy compilers */
157157

158158
/* ===========================================================================
159159
* Update a hash value with the given input byte
160-
* IN assertion: all calls to to UPDATE_HASH are made with consecutive
160+
* IN assertion: all calls to UPDATE_HASH are made with consecutive
161161
* input characters, so that a running hash key can be computed from the
162162
* previous key instead of complete recalculation each time.
163163
*/
@@ -170,7 +170,7 @@ struct static_tree_desc_s {int dummy;}; /* for buggy compilers */
170170
* the previous length of the hash chain.
171171
* If this file is compiled with -DFASTEST, the compression level is forced
172172
* to 1, and no hash chains are maintained.
173-
* IN assertion: all calls to to INSERT_STRING are made with consecutive
173+
* IN assertion: all calls to INSERT_STRING are made with consecutive
174174
* input characters and the first MIN_MATCH bytes of str are valid
175175
* (except for the last MIN_MATCH-1 bytes of the input file).
176176
*/

Modules/zlib/inftrees.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ typedef struct {
4141
examples/enough.c found in the zlib distribtution. The arguments to that
4242
program are the number of symbols, the initial root table size, and the
4343
maximum bit length of a code. "enough 286 9 15" for literal/length codes
44-
returns returns 852, and "enough 30 6 15" for distance codes returns 592.
44+
returns 852, and "enough 30 6 15" for distance codes returns 592.
4545
The initial root table size (9 or 6) is found in the fifth argument of the
4646
inflate_table() calls in inflate.c and infback.c. If the root table size is
4747
changed, then these maximum sizes would be need to be recalculated and

Modules/zlib/zlib.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -812,7 +812,7 @@ ZEXTERN int ZEXPORT inflateSync OF((z_streamp strm));
812812
inflateSync returns Z_OK if a full flush point has been found, Z_BUF_ERROR
813813
if no more input was provided, Z_DATA_ERROR if no flush point has been
814814
found, or Z_STREAM_ERROR if the stream structure was inconsistent. In the
815-
success case, the application may save the current current value of total_in
815+
success case, the application may save the current value of total_in
816816
which indicates where valid compressed data was found. In the error case,
817817
the application may repeatedly call inflateSync, providing more input each
818818
time, until success or end of the input data.

0 commit comments

Comments
 (0)