Bitset: Make bool() operator explicit.

This commit is contained in:
Scott Mansell
2015-10-04 01:10:11 +13:00
parent 18142eddb4
commit 5f8a67250f
2 changed files with 2 additions and 3 deletions

View File

@ -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,