@@ -131,6 +131,14 @@ As well as complex arithmetic expressions:
131
131
~~~~~~^~~
132
132
ZeroDivisionError : division by zero
133
133
134
+ Additionally, the information used by the enhanced traceback feature
135
+ is made available via a general API, that can be used to correlate
136
+ :term: `bytecode ` :ref: `instructions <bytecodes >` with source code location.
137
+ This information can be retrieved using:
138
+
139
+ - The :meth: `codeobject.co_positions ` method in Python.
140
+ - The :c:func: `PyCode_Addr2Location ` function in the C API.
141
+
134
142
See :pep: `657 ` for more details. (Contributed by Pablo Galindo, Batuhan Taskaya
135
143
and Ammar Askar in :issue: `43950 `.)
136
144
@@ -144,22 +152,6 @@ and Ammar Askar in :issue:`43950`.)
144
152
or the :envvar: `PYTHONNODEBUGRANGES ` environment variable.
145
153
146
154
147
- Column information for code objects
148
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
149
-
150
- The information used by the enhanced traceback feature is made available as a
151
- general API that can be used to correlate bytecode instructions with source
152
- code. This information can be retrieved using:
153
-
154
- - The :meth: `codeobject.co_positions ` method in Python.
155
- - The :c:func: `PyCode_Addr2Location ` function in the C-API.
156
-
157
- The :option: `-X ` ``no_debug_ranges `` option and the environment variable
158
- :envvar: `PYTHONNODEBUGRANGES ` can be used to disable this feature.
159
-
160
- See :pep: `657 ` for more details. (Contributed by Pablo Galindo, Batuhan Taskaya
161
- and Ammar Askar in :issue: `43950 `.)
162
-
163
155
Exceptions can be enriched with notes (PEP 678)
164
156
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
165
157
0 commit comments