Simplify the Tile::operator==() method

This commit is contained in:
Olivier Teulière 2012-02-18 21:19:11 +01:00
parent 1336e3b65d
commit 221158e19a

View file

@ -162,13 +162,8 @@ bool Tile::operator<(const Tile &iOther) const
bool Tile::operator==(const Tile &iOther) const bool Tile::operator==(const Tile &iOther) const
{ {
if (m_joker || iOther.m_joker) return m_char == iOther.m_char
{ && m_joker == iOther.m_joker;
if (m_joker != iOther.m_joker)
return false;
return m_char == iOther.m_char;
}
return m_char == iOther.m_char;
} }