Add Python support for std::unique_ptr inputs
Equivalent to Java/C# implementation.
This commit is contained in:
parent
c737bd5713
commit
c3c061cac8
8 changed files with 103 additions and 9 deletions
|
|
@ -19,6 +19,7 @@
|
|||
#endif
|
||||
#define %varnullref_fmt(_type,_name) %nullref_fmt() %varfail_fmt(_type, _name)
|
||||
#define %outnullref_fmt(_type) %nullref_fmt() %outfail_fmt(_type)
|
||||
#define %releasenotownedfail_fmt(_type,_name,_argn) "in method '" `_name` "', cannot release ownership as memory is not owned for argument " `_argn`" of type '" `_type`"'"
|
||||
|
||||
/* setting an error */
|
||||
#define %error(code,msg...) SWIG_Error(code, msg)
|
||||
|
|
|
|||
|
|
@ -140,6 +140,7 @@
|
|||
#define %argument_nullref(type, name, argn) SWIG_exception_fail(SWIG_ValueError, %argnullref_fmt(type, name, argn))
|
||||
#define %variable_fail(code, type, name) SWIG_exception_fail(%default_code(code), %varfail_fmt(type, name))
|
||||
#define %variable_nullref(type, name) SWIG_exception_fail(SWIG_ValueError, %varnullref_fmt(type, name))
|
||||
#define %releasenotowned_fail(code, type, name, argn) SWIG_exception_fail(%default_code(code), %releasenotownedfail_fmt(type, name, argn))
|
||||
|
||||
#if defined(SWIG_DIRECTOR_TYPEMAPS)
|
||||
#define %dirout_fail(code, type) SWIG_DirOutFail(%default_code(code), %outfail_fmt(type))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue