massive typemap unification
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7676 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
5bbd841acc
commit
7e5e4fd1f9
144 changed files with 6378 additions and 7248 deletions
|
|
@ -4,23 +4,5 @@
|
|||
(std::pair,std::vector,std::list,etc) return tuples.
|
||||
*/
|
||||
|
||||
%fragment("t_output_helper","header") %{
|
||||
SWIGINTERN PyObject*
|
||||
t_output_helper(PyObject* target, PyObject* o) {
|
||||
if (!target) {
|
||||
target = o;
|
||||
} else if (target == Py_None) {
|
||||
Py_DECREF(target);
|
||||
target = o;
|
||||
} else {
|
||||
if (!PyList_Check(target)) {
|
||||
PyObject *o2 = target;
|
||||
target = PyList_New(1);
|
||||
PyList_SetItem(target, 0, o2);
|
||||
}
|
||||
PyList_Append(target,o);
|
||||
Py_DECREF(o);
|
||||
}
|
||||
return target;
|
||||
}
|
||||
%}
|
||||
#warning "Deprecated file: Don't use t_output_helper anymore,"
|
||||
#warning "use SWIG_Python_AppendResult or SWIG_append_result instead."
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue