Skip to content

basicblock_addop Assertion: while-loop with if-expression #109823

Closed

Description

@15r10nk

Bug report

Bug description:

while x:
    0 if 1 else 0 # 1 can not be 0 to reproduce this bug

output (Python 3.12.0rc3+):

python: Python/flowgraph.c:114: basicblock_addop: Assertion `0 <= oparg && oparg < (1 << 30)' failed.

I tested this with the current 3.12 branch (6f1d455)
@iritkatriel I think this is again something like #109719 or #109627

CPython versions tested on:

3.12

Operating systems tested on:

Linux

Linked PRs

Activity

  1. added
    type-bug
    on Sep 25, 2023
  2. added
    3.12
    3.13
    on Sep 25, 2023
  3. added 2 commits that reference this issue on Sep 25, 2023
  4. added a commit that references this issue on Sep 25, 2023
  5. added a commit that references this issue on Sep 25, 2023
  6. added a commit that references this issue on Sep 26, 2023
  7. added a commit that references this issue on Sep 28, 2023
  8. added a commit that references this issue on Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

3.123.13release-blockertype-bug

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions