add operator < for DEBUG
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8186 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
66efeaa788
commit
c2b4305599
1 changed files with 7 additions and 2 deletions
|
|
@ -392,6 +392,11 @@ namespace swig
|
|||
return _index - ri._index;
|
||||
}
|
||||
|
||||
bool operator < (const self& ri) const
|
||||
{
|
||||
return _index < ri._index;
|
||||
}
|
||||
|
||||
reference
|
||||
operator[](difference_type n) const
|
||||
{
|
||||
|
|
@ -531,14 +536,14 @@ namespace swig
|
|||
const_iterator(swig::PySwigIterator *iter),
|
||||
const_reverse_iterator(swig::PySwigIterator *iter) {
|
||||
if (SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::PySwigIterator::descriptor(), 0) != SWIG_OK) {
|
||||
%argument_fail(SWIG_TypeError, "$type", $argnum);
|
||||
%argument_fail(SWIG_TypeError, "$type", $symname, $argnum);
|
||||
}
|
||||
if (iter) {
|
||||
swig::PySwigIterator_T<$type > *iter_t
|
||||
= dynamic_cast<swig::PySwigIterator_T<$type > *>(iter);
|
||||
$1 = iter_t->get_current();
|
||||
} else {
|
||||
%argument_fail(SWIG_TypeError, "$type", $argnum);
|
||||
%argument_fail(SWIG_TypeError, "$type", $symname, $argnum);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue