diff options
Diffstat (limited to 'backend/src/ir/instruction.cpp')
-rw-r--r-- | backend/src/ir/instruction.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/backend/src/ir/instruction.cpp b/backend/src/ir/instruction.cpp index 18bb3d49..f5580cbc 100644 --- a/backend/src/ir/instruction.cpp +++ b/backend/src/ir/instruction.cpp @@ -749,7 +749,7 @@ namespace ir { const Function &fn, std::string &whyNot) { - if (UNLIKELY(uint32_t(ID) >= fn.regNum())) { + if (UNLIKELY(ID.value() >= fn.regNum())) { whyNot = "Out-of-bound destination register index"; return false; } @@ -893,9 +893,8 @@ namespace ir { return false; const RegisterFamily family = getFamily(this->type); for (uint32_t srcID = 0; srcID < 2; ++srcID) - if (UNLIKELY(checkRegisterData(family, src[srcID], fn, whyNot) == false)) { + if (UNLIKELY(checkRegisterData(family, src[srcID], fn, whyNot) == false)) return false; - } return true; } |