Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove unused internal Runtime.GetBoundArgTuple
  • Loading branch information
Rickard Holmberg committed Jun 21, 2017
commit f72c8cc8cda53cd14ce9adc13db1284e50d82eae
23 changes: 0 additions & 23 deletions src/runtime/runtime.cs
Original file line number Diff line number Diff line change
Expand Up @@ -378,29 +378,6 @@ internal static void CheckExceptionOccurred()
}
}

internal static IntPtr GetBoundArgTuple(IntPtr obj, IntPtr args)
{
if (PyObject_TYPE(args) != PyTupleType)
{
Exceptions.SetError(Exceptions.TypeError, "tuple expected");
return IntPtr.Zero;
}
int size = PyTuple_Size(args);
IntPtr items = PyTuple_New(size + 1);
PyTuple_SetItem(items, 0, obj);
XIncref(obj);

for (var i = 0; i < size; i++)
{
IntPtr item = PyTuple_GetItem(args, i);
XIncref(item);
PyTuple_SetItem(items, i + 1, item);
}

return items;
}


internal static IntPtr ExtendTuple(IntPtr t, params IntPtr[] args)
{
int size = PyTuple_Size(t);
Expand Down