Bitset: Make bool() operator explicit.
This commit is contained in:
parent
18142eddb4
commit
5f8a67250f
|
@ -164,8 +164,7 @@ public:
|
|||
BitSet& operator|=(BitSet other) { return *this = *this | other; }
|
||||
BitSet& operator&=(BitSet other) { return *this = *this & other; }
|
||||
BitSet& operator^=(BitSet other) { return *this = *this ^ other; }
|
||||
operator u32() const = delete;
|
||||
operator bool() const { return m_val != 0; }
|
||||
explicit operator bool() const { return m_val != 0; }
|
||||
|
||||
// Warning: Even though on modern CPUs this is a single fast instruction,
|
||||
// Dolphin's official builds do not currently assume POPCNT support on x86,
|
||||
|
|
|
@ -75,7 +75,7 @@ public:
|
|||
|
||||
void SetLevel(LogTypes::LOG_LEVELS level) { m_level = level; }
|
||||
|
||||
bool HasListeners() const { return m_listener_ids; }
|
||||
bool HasListeners() const { return bool(m_listener_ids); }
|
||||
|
||||
typedef class BitSet32::Iterator iterator;
|
||||
iterator begin() const { return m_listener_ids.begin(); }
|
||||
|
|
Loading…
Reference in New Issue