summaryrefslogtreecommitdiffstats
path: root/InternalDocs
diff options
context:
space:
mode:
authorYan Yanchii <yyanchiy@gmail.com>2024-12-22 16:34:16 (GMT)
committerGitHub <noreply@github.com>2024-12-22 16:34:16 (GMT)
commitf420bdd29fbc1a97ad20d88075c38c937c1f8479 (patch)
tree4aa306502e0d79ddee0998a60dfde491d238df26 /InternalDocs
parentb66a4ad9fc32b63da2ba10db24cbc8f4e29f781a (diff)
downloadcpython-f420bdd29fbc1a97ad20d88075c38c937c1f8479.zip
cpython-f420bdd29fbc1a97ad20d88075c38c937c1f8479.tar.gz
cpython-f420bdd29fbc1a97ad20d88075c38c937c1f8479.tar.bz2
gh-119786: Fix typos in `InternalDocs/interpreter.md` (#128174)
Diffstat (limited to 'InternalDocs')
-rw-r--r--InternalDocs/interpreter.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/InternalDocs/interpreter.md b/InternalDocs/interpreter.md
index fa4a54f..5270279 100644
--- a/InternalDocs/interpreter.md
+++ b/InternalDocs/interpreter.md
@@ -20,7 +20,7 @@ When the interpreter's
[`PyEval_EvalCode()`](https://docs.python.org/3.14/c-api/veryhigh.html#c.PyEval_EvalCode)
function is called to execute a `CodeObject`, it constructs a [`Frame`](frames.md) and calls
[`_PyEval_EvalFrame()`](https://docs.python.org/3.14/c-api/veryhigh.html#c.PyEval_EvalCode)
-to execute the code object in this frame. The frame hold the dynamic state of the
+to execute the code object in this frame. The frame holds the dynamic state of the
`CodeObject`'s execution, including the instruction pointer, the globals and builtins.
It also has a reference to the `CodeObject` itself.
@@ -153,9 +153,9 @@ More information about the use of inline caches can be found in
Most instructions read or write some data in the form of object references (`PyObject *`).
The CPython bytecode interpreter is a stack machine, meaning that its instructions operate
by pushing data onto and popping it off the stack.
-The stack is forms part of the frame for the code object. Its maximum depth is calculated
+The stack forms part of the frame for the code object. Its maximum depth is calculated
by the compiler and stored in the `co_stacksize` field of the code object, so that the
-stack can be pre-allocated is a contiguous array of `PyObject*` pointers, when the frame
+stack can be pre-allocated as a contiguous array of `PyObject*` pointers, when the frame
is created.
The stack effects of each instruction are also exposed through the
@@ -462,7 +462,7 @@ set of values that allows them to:
2. Perform the operation quickly.
This requires that the set of values is chosen such that membership can be
-tested quickly and that membership is sufficient to allow the operation to
+tested quickly and that membership is sufficient to allow the operation to be
performed quickly.
For example, `LOAD_GLOBAL_MODULE` is specialized for `globals()`