Repository navigation
Commit 64feee6
committed
fix(cuda.bindings): accept ints in handle-array setters under Cython 3.3
Cython 3.3 enforces declared list item types at runtime. The pArray
setters on CUeglFrame.frame and cudaEglFrame.frame were annotated as
list[CUarray] / list[cudaArray_t], so passing plain ints raised
TypeError. The fix is a generator change (cybind !621, cython_gen):
widen the annotation to list[CUarray | int] / list[cudaArray_t | int].
The setter body already converts each element with int() before casting,
so accepting plain ints was always safe; the annotation was just narrower
than the implementation.
Generated files updated from cybind branch accept-int-handle-arrays
(da353763) against CTK 12.9 (cuda_bindings_12) and 13.5 (cuda_bindings_13).
Seals recomputed. Test workarounds that wrapped plain ints in handle
objects are reverted to their original plain-int form.1 parent 79ecfe4 commit 64feee6
8 files changed
Lines changed: 16 additions & 16 deletions
File tree
- cuda_bindings_12
- cuda/bindings
- tests
- cuda_bindings_13
- cuda/bindings
- tests
- legacy_api
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
22422 | 22422 | | |
22423 | 22423 | | |
22424 | 22424 | | |
22425 | | - | |
| 22425 | + | |
22426 | 22426 | | |
22427 | 22427 | | |
22428 | 22428 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
18808 | 18808 | | |
18809 | 18809 | | |
18810 | 18810 | | |
18811 | | - | |
| 18811 | + | |
18812 | 18812 | | |
18813 | 18813 | | |
18814 | 18814 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
863 | 863 | | |
864 | 864 | | |
865 | 865 | | |
866 | | - | |
| 866 | + | |
867 | 867 | | |
868 | 868 | | |
869 | 869 | | |
870 | 870 | | |
871 | | - | |
| 871 | + | |
872 | 872 | | |
873 | 873 | | |
874 | 874 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1194 | 1194 | | |
1195 | 1195 | | |
1196 | 1196 | | |
1197 | | - | |
| 1197 | + | |
1198 | 1198 | | |
1199 | 1199 | | |
1200 | 1200 | | |
1201 | 1201 | | |
1202 | | - | |
| 1202 | + | |
1203 | 1203 | | |
1204 | 1204 | | |
1205 | 1205 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
26277 | 26277 | | |
26278 | 26278 | | |
26279 | 26279 | | |
26280 | | - | |
| 26280 | + | |
26281 | 26281 | | |
26282 | 26282 | | |
26283 | 26283 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
20219 | 20219 | | |
20220 | 20220 | | |
20221 | 20221 | | |
20222 | | - | |
| 20222 | + | |
20223 | 20223 | | |
20224 | 20224 | | |
20225 | 20225 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
746 | 746 | | |
747 | 747 | | |
748 | 748 | | |
749 | | - | |
| 749 | + | |
750 | 750 | | |
751 | 751 | | |
752 | 752 | | |
753 | 753 | | |
754 | | - | |
| 754 | + | |
755 | 755 | | |
756 | 756 | | |
757 | 757 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1289 | 1289 | | |
1290 | 1290 | | |
1291 | 1291 | | |
1292 | | - | |
| 1292 | + | |
1293 | 1293 | | |
1294 | 1294 | | |
1295 | 1295 | | |
1296 | 1296 | | |
1297 | | - | |
| 1297 | + | |
1298 | 1298 | | |
1299 | 1299 | | |
1300 | 1300 | | |
| |||
0 commit comments