Skip to content

Exception unwinding might be broken when handling a memory error. #132508

Closed
@markshannon

Description

@markshannon

Bug report

Bug description:

Exception unwinding can sometimes push an integer to the stack to support re-raising an exception from an earlier position. Creating this integer might need memory allocation and could fail when handling a memory error.

This is incredibly unlikely to ever happen, but we can fix it using tagged integers, which do not require any allocation, so we might as well.

CPython versions tested on:

CPython main branch

Operating systems tested on:

No response

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    interpreter-core(Objects, Python, Grammar, and Parser dirs)type-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions