8000 fixed: TupleCodec not respecting element type · pythonnet/pythonnet@d48f512 · GitHub
[go: up one dir, main page]

Skip to content

Commit d48f512

Browse files
committed
fixed: TupleCodec not respecting element type
1 parent dee41b8 commit d48f512

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/runtime/Codecs/TupleCodecs.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ public PyObject TryEncode(object value)
3434
foreach (FieldInfo field in tupleType.GetFields())
3535
{
3636
var item = field.GetValue(value);
37-
IntPtr pyItem = Converter.ToPython(item);
37+
IntPtr pyItem = Converter.ToPython(item, field.FieldType);
3838
Runtime.PyTuple_SetItem(tuple, fieldIndex, pyItem);
3939
fieldIndex++;
4040
}

0 commit comments

Comments
 (0)
0