Use %{ %} instead of { } after %pythoncode
Simpler and safer change to address PR#357.
This commit is contained in:
parent
3bc5348bd2
commit
c8a7322a4d
6 changed files with 23 additions and 23 deletions
|
|
@ -344,8 +344,8 @@ namespace swig
|
|||
%feature("python:slot", "tp_iternext", functype="iternextfunc") SwigPyIterator::__next__;
|
||||
#else
|
||||
%extend SwigPyIterator {
|
||||
%pythoncode {def __iter__(self):
|
||||
return self}
|
||||
%pythoncode %{def __iter__(self):
|
||||
return self%}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue