feat: add support for CPython 3.15 - #192
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #192 +/- ##
==========================================
+ Coverage 95.45% 95.57% +0.11%
==========================================
Files 7 7
Lines 2135 2147 +12
Branches 459 461 +2
==========================================
+ Hits 2038 2052 +14
+ Misses 54 53 -1
+ Partials 43 42 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Thanks for starting work on this ! It is nice to see all tests passing with such a small changelog. |
f2413c9 to
aca90d2
Compare
|
@MatthieuDartiailh I think this is ready now that's been tested against the 3.15rc |
MatthieuDartiailh
left a comment
There was a problem hiding this comment.
Some small comments.
I did not realize 3.15 rc was out. I am late in publishing new releases in several project, thanks for the reminder.
| BUILTIN_LIST = 5 | ||
| BUILTIN_SET = 6 | ||
| CONSTANT_NONE = 7 | ||
| CONSTANT_EMPTY_STR = 8 | ||
| CONSTANT_TRUE = 9 | ||
| CONSTANT_FALSE = 10 | ||
| CONSTANT_MINUS_ONE = 11 |
There was a problem hiding this comment.
Thise should be gated by a version check.
| "GET_YIELD_FROM_ITER": ( | ||
| -1, | ||
| 1, | ||
| ), # removed in 3.15, filtered by if k in _opcode.opmap |
There was a problem hiding this comment.
| "GET_YIELD_FROM_ITER": ( | |
| -1, | |
| 1, | |
| ), # removed in 3.15, filtered by if k in _opcode.opmap | |
| # removed in 3.15, filtered by if k in _opcode.opmap | |
| "GET_YIELD_FROM_ITER": (-1, 1), |
| # In 3.15, GET_ITER pushes (iter, null_or_index); FOR_ITER always pushes the | ||
| # next value (+1). When exhausted it jumps to END_FOR (which pops it) then | ||
| # POP_ITER cleans up (iter, null_or_index). Matches dis.stack_effect = 1 always. | ||
| "FOR_ITER": (lambda __effect, __arg, __jump: (0, 1)) |
There was a problem hiding this comment.
I think we should have -2, +3 then to encode the requirement to have the iterator and and index on the stack.
| function=True, | ||
| ) | ||
|
|
||
| def test_import(self): |
There was a problem hiding this comment.
A comment explaining why this is worth testing would be welcome.
No description provided.