Correct Python docs example

Fix PyTuple_SetItem in argout typemap
Fix from Bob Hood on swig-user mailing list
[skip ci]
This commit is contained in:
William S Fulton 2016-04-30 12:58:22 +01:00
commit a8110e3761

View file

@ -4899,7 +4899,7 @@ A typemap can be used to handle this case as follows :
if (!PyTuple_Check($result)) { if (!PyTuple_Check($result)) {
PyObject *o2 = $result; PyObject *o2 = $result;
$result = PyTuple_New(1); $result = PyTuple_New(1);
PyTuple_SetItem(target,0,o2); PyTuple_SetItem($result,0,o2);
} }
o3 = PyTuple_New(1); o3 = PyTuple_New(1);
PyTuple_SetItem(o3,0,o); PyTuple_SetItem(o3,0,o);