diff options
author | Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> | 2021-09-07 11:36:43 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-07 11:36:43 (GMT) |
commit | fc840736e54da0557616882012f362b809490165 (patch) | |
tree | 9f1ec23eada4342c400b013102b782820418f7a2 /Doc/whatsnew | |
parent | 608a6292366ebba20f33d93d8b52cbb928429e47 (diff) | |
download | cpython-fc840736e54da0557616882012f362b809490165.zip cpython-fc840736e54da0557616882012f362b809490165.tar.gz cpython-fc840736e54da0557616882012f362b809490165.tar.bz2 |
bpo-44964: Add a note explaining the new semantics of f_last_i in frame objects (GH-28200)
(cherry picked from commit fa2c0b85a8d5c9486661083afdf38cbaadb3432a)
Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
Diffstat (limited to 'Doc/whatsnew')
-rw-r--r-- | Doc/whatsnew/3.10.rst | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/Doc/whatsnew/3.10.rst b/Doc/whatsnew/3.10.rst index 068eb76..dbf8923 100644 --- a/Doc/whatsnew/3.10.rst +++ b/Doc/whatsnew/3.10.rst @@ -1944,6 +1944,12 @@ Changes in the C API source_buf = PyBytes_AsString(source_bytes_object); code = Py_CompileString(source_buf, filename, Py_file_input); + * For ``FrameObject`` objects, the ``f_lasti`` member now represents a wordcode + offset instead of a simple offset into the bytecode string. This means that this + number needs to be multiplied by 2 to be used with APIs that expect a byte offset + instead (like :c:func:`PyCode_Addr2Line` for example). Notice as well that the + ``f_lasti`` member of ``FrameObject`` objects is not considered stable. + CPython bytecode changes ======================== |