forked from OSchip/llvm-project
Added a less than operator that will compare the internal opaque pointer values so SBBroadcaster objects can be contained in ordered containers or sorted.
llvm-svn: 120967
This commit is contained in:
parent
70fbbf534b
commit
f7d6a2a6a8
|
@ -58,12 +58,22 @@ public:
|
|||
RemoveListener (const lldb::SBListener &listener, uint32_t event_mask = UINT32_MAX);
|
||||
|
||||
#ifndef SWIG
|
||||
// This comparison is checking if the internal opaque pointer value
|
||||
// is equal to that in "rhs".
|
||||
bool
|
||||
operator == (const lldb::SBBroadcaster &rhs) const;
|
||||
|
||||
// This comparison is checking if the internal opaque pointer value
|
||||
// is not equal to that in "rhs".
|
||||
bool
|
||||
operator != (const lldb::SBBroadcaster &rhs) const;
|
||||
|
||||
// This comparison is checking if the internal opaque pointer value
|
||||
// is less than that in "rhs" so SBBroadcaster objects can be contained
|
||||
// in ordered containers.
|
||||
bool
|
||||
operator < (const lldb::SBBroadcaster &rhs) const;
|
||||
|
||||
#endif
|
||||
|
||||
protected:
|
||||
|
|
|
@ -189,3 +189,9 @@ SBBroadcaster::operator != (const SBBroadcaster &rhs) const
|
|||
{
|
||||
return m_opaque_ptr != rhs.m_opaque_ptr;
|
||||
}
|
||||
|
||||
bool
|
||||
SBBroadcaster::operator < (const SBBroadcaster &rhs) const
|
||||
{
|
||||
return m_opaque_ptr < rhs.m_opaque_ptr;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue