Skip to content

Commit 6a97929

Browse files
authored
Fix typos in comments (#120188)
1 parent 57ad769 commit 6a97929

11 files changed

+11
-11
lines changed

Include/ceval.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ PyAPI_FUNC(int) Py_MakePendingCalls(void);
4242
level exceeds "current recursion limit + 50". By construction, this
4343
protection can only be triggered when the "overflowed" flag is set. It
4444
means the cleanup code has itself gone into an infinite loop, or the
45-
RecursionError has been mistakingly ignored. When this protection is
45+
RecursionError has been mistakenly ignored. When this protection is
4646
triggered, the interpreter aborts with a Fatal Error.
4747
4848
In addition, the "overflowed" flag is automatically reset when the

Include/cpython/object.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ PyAPI_FUNC(PyObject *) _PyObject_FunctionStr(PyObject *);
313313
* triggered as a side-effect of `dst` getting torn down no longer believes
314314
* `dst` points to a valid object.
315315
*
316-
* Temporary variables are used to only evalutate macro arguments once and so
316+
* Temporary variables are used to only evaluate macro arguments once and so
317317
* avoid the duplication of side effects. _Py_TYPEOF() or memcpy() is used to
318318
* avoid a miscompilation caused by type punning. See Py_CLEAR() comment for
319319
* implementation details about type punning.

Include/cpython/pyframe.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ struct _PyInterpreterFrame;
2828
* Does not raise an exception. */
2929
PyAPI_FUNC(PyObject *) PyUnstable_InterpreterFrame_GetCode(struct _PyInterpreterFrame *frame);
3030

31-
/* Returns a byte ofsset into the last executed instruction.
31+
/* Returns a byte offset into the last executed instruction.
3232
* Does not raise an exception. */
3333
PyAPI_FUNC(int) PyUnstable_InterpreterFrame_GetLasti(struct _PyInterpreterFrame *frame);
3434

Include/internal/mimalloc/mimalloc/atomic.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ terms of the MIT license. A copy of the license can be found in the file
1111
// --------------------------------------------------------------------------------------------
1212
// Atomics
1313
// We need to be portable between C, C++, and MSVC.
14-
// We base the primitives on the C/C++ atomics and create a mimimal wrapper for MSVC in C compilation mode.
14+
// We base the primitives on the C/C++ atomics and create a minimal wrapper for MSVC in C compilation mode.
1515
// This is why we try to use only `uintptr_t` and `<type>*` as atomic types.
1616
// To gain better insight in the range of used atomics, we use explicitly named memory order operations
1717
// instead of passing the memory order as a parameter.

Include/internal/mimalloc/mimalloc/internal.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ terms of the MIT license. A copy of the license can be found in the file
1010

1111

1212
// --------------------------------------------------------------------------
13-
// This file contains the interal API's of mimalloc and various utility
13+
// This file contains the internal API's of mimalloc and various utility
1414
// functions and macros.
1515
// --------------------------------------------------------------------------
1616

Include/internal/pycore_initconfig.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ typedef enum {
157157
/* For now, this means the GIL is enabled.
158158
159159
gh-116329: This will eventually change to "the GIL is disabled but can
160-
be reenabled by loading an incompatible extension module." */
160+
be re-enabled by loading an incompatible extension module." */
161161
_PyConfig_GIL_DEFAULT = -1,
162162

163163
/* The GIL has been forced off or on, and will not be affected by module loading. */

Include/internal/pycore_instruments.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ typedef uint32_t _PyMonitoringEventSet;
2323
#define PY_MONITORING_PROFILER_ID 2
2424
#define PY_MONITORING_OPTIMIZER_ID 5
2525

26-
/* Internal IDs used to suuport sys.setprofile() and sys.settrace() */
26+
/* Internal IDs used to support sys.setprofile() and sys.settrace() */
2727
#define PY_MONITORING_SYS_PROFILE_ID 6
2828
#define PY_MONITORING_SYS_TRACE_ID 7
2929

Include/internal/pycore_lock.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ typedef enum _PyLockFlags {
116116
extern PyLockStatus
117117
_PyMutex_LockTimed(PyMutex *m, PyTime_t timeout_ns, _PyLockFlags flags);
118118

119-
// Lock a mutex with aditional options. See _PyLockFlags for details.
119+
// Lock a mutex with additional options. See _PyLockFlags for details.
120120
static inline void
121121
PyMutex_LockFlags(PyMutex *m, _PyLockFlags flags)
122122
{

Include/internal/pycore_pythread.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ PyAPI_FUNC(int) PyThread_start_joinable_thread(void (*func)(void *),
147147
PyAPI_FUNC(int) PyThread_join_thread(PyThread_handle_t);
148148
/*
149149
* Detach a thread started with `PyThread_start_joinable_thread`, such
150-
* that its resources are relased as soon as it exits.
150+
* that its resources are released as soon as it exits.
151151
* This function cannot be interrupted. It returns 0 on success,
152152
* a non-zero value on failure.
153153
*/

Include/internal/pycore_unicodeobject.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ extern PyObject* _PyUnicode_EncodeCharmap(
189189

190190
/* --- Decimal Encoder ---------------------------------------------------- */
191191

192-
// Coverts a Unicode object holding a decimal value to an ASCII string
192+
// Converts a Unicode object holding a decimal value to an ASCII string
193193
// for using in int, float and complex parsers.
194194
// Transforms code points that have decimal digit property to the
195195
// corresponding ASCII digit code points. Transforms spaces to ASCII.

Include/structmember.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ extern "C" {
1111
* New definitions are in descrobject.h.
1212
*
1313
* However, there's nothing wrong with old code continuing to use it,
14-
* and there's not much mainenance overhead in maintaining a few aliases.
14+
* and there's not much maintenance overhead in maintaining a few aliases.
1515
* So, don't be too eager to convert old code.
1616
*
1717
* It uses names not prefixed with Py_.

0 commit comments

Comments
 (0)