Commit 3f11f26
authored
[mypyc] feat: support negative index in TupleGet op
This PR modifies `TupleGet.__init__` to automatically convert negative indexes to positive indexes instead of crashing at the assert
This won't change functionality on its own, since none of the existing calling locations can pass a negative value, but will allow us to pass negative values in python#19972 so I think we should consider this PR a prerequisite to that one1 parent a62f273 commit 3f11f26
1 file changed
+7
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1045 | 1045 | | |
1046 | 1046 | | |
1047 | 1047 | | |
| 1048 | + | |
| 1049 | + | |
| 1050 | + | |
| 1051 | + | |
1048 | 1052 | | |
1049 | 1053 | | |
1050 | | - | |
1051 | | - | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
1052 | 1057 | | |
1053 | 1058 | | |
1054 | 1059 | | |
| |||
0 commit comments