reuse operator bool() check in compatibility_iterator::IndexOf() instead of rewriting it
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38240 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -191,11 +191,8 @@ private:
|
|||||||
} \
|
} \
|
||||||
int IndexOf() const \
|
int IndexOf() const \
|
||||||
{ \
|
{ \
|
||||||
return m_list ? \
|
return *this ? std::distance( m_list->begin(), m_iter ) \
|
||||||
m_iter != m_list->end() ? \
|
: wxNOT_FOUND; \
|
||||||
std::distance( m_list->begin(), m_iter ) : \
|
|
||||||
wxNOT_FOUND : \
|
|
||||||
wxNOT_FOUND; \
|
|
||||||
} \
|
} \
|
||||||
}; \
|
}; \
|
||||||
public: \
|
public: \
|
||||||
|
Reference in New Issue
Block a user