Skip to content

PEP 626: Add length parameter to PyLineTable_InitAddressRange#1939

Merged
gvanrossum merged 2 commits intopython:masterfrom
markshannon:pep-626-add-length-parameter
Apr 28, 2021
Merged

PEP 626: Add length parameter to PyLineTable_InitAddressRange#1939
gvanrossum merged 2 commits intopython:masterfrom
markshannon:pep-626-add-length-parameter

Conversation

@markshannon
Copy link
Copy Markdown
Member

Allows line tables that are not sentinel terminated and makes the extent of the line table explicit.

See https://bugs.python.org/issue42739 and python/cpython#25657

…les that are not sentinel terminated and makes the extent of the line table explicit.
@markshannon markshannon changed the title Add length parameter to PyLineTable_InitAddressRange. … Add length parameter to PyLineTable_InitAddressRange Apr 27, 2021
@markshannon markshannon changed the title Add length parameter to PyLineTable_InitAddressRange PEP 626: Add length parameter to PyLineTable_InitAddressRange Apr 27, 2021
@gvanrossum
Copy link
Copy Markdown
Member

I agree that this is a better solution. But since this PEP was accepted with the old API shape, could you add a note telling the reader that this detail was updated? Otherwise LGTM.

@markshannon markshannon force-pushed the pep-626-add-length-parameter branch from 8170a04 to 50fd7c0 Compare April 28, 2021 15:05
@markshannon
Copy link
Copy Markdown
Member Author

Implementing zero-width ranges lead to me to want to change the opaque part of PyCodeAddressRange yet again.
So I've changed the PEP to make it clearer that the opaque part of the struct is indeed opaque and may change.

@markshannon
Copy link
Copy Markdown
Member Author

I've also updated python/cpython#25657 to use the new struct.

@gvanrossum gvanrossum merged commit c176458 into python:master Apr 28, 2021
@markshannon markshannon deleted the pep-626-add-length-parameter branch March 23, 2022 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants