Skip to content
Permalink
Browse files
Merge pull request #6645 from JosJuice/tie-constexpr
x64Emitter: Don't assume that std::tie is constexpr
  • Loading branch information
lioncash committed Apr 15, 2018
2 parents 4592369 + 8a146d5 commit eecdb51
Showing 1 changed file with 4 additions and 2 deletions.
@@ -120,8 +120,10 @@ struct OpArg
}
constexpr bool operator==(const OpArg& b) const
{
return std::tie(scale, offsetOrBaseReg, indexReg, offset, operandReg) ==
std::tie(b.scale, b.offsetOrBaseReg, b.indexReg, b.offset, b.operandReg);
// TODO: Use std::tie here once Dolphin requires C++17. (We can't do it immediately,
// (because we still support some older versions of GCC where std::tie is not constexpr.)
return operandReg == b.operandReg && scale == b.scale && offsetOrBaseReg == b.offsetOrBaseReg &&
indexReg == b.indexReg && offset == b.offset;
}
constexpr bool operator!=(const OpArg& b) const { return !operator==(b); }
u64 Imm64() const

0 comments on commit eecdb51

Please sign in to comment.