8000 Workaround for geninterop failure to handle non-pointer fields · pythonnet/pythonnet@88d98f2 · GitHub
[go: up one dir, main page]

Skip to content

Commit 88d98f2

Browse files
committed
Workaround for geninterop failure to handle non-pointer fields
1 parent f3face0 commit 88d98f2

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/runtime/Native/TypeOffset313.cs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,14 @@ public TypeOffset313() { }
7575
public int tp_version_tag { get; private set; }
7676
public int tp_finalize { get; private set; }
7777
public int tp_vectorcall { get; private set; }
78+
// This is an error in our generator:
79+
//
80+
// The fields below are actually not pointers (like we incorrectly
81+
// assume for all other fields) but instead a char (1 byte) and a short
82+
// (2 bytes). By dropping one of the fields, we still get the correct
83+
// overall size of the struct.
7884
public int tp_watched { get; private set; }
79-
public int tp_versions_used { get; private set; }
85+
// public int tp_versions_used { get; private set; }
8086
public int am_await { get; private set; }
8187
public int am_aiter { get; private set; }
8288
public int am_anext { get; private set; }

0 commit comments

Comments
 (0)
0