Forward declare IR::Opcode and IR::Type where possible

This commit is contained in:
MerryMage 2018-02-11 11:46:18 +00:00
parent 6c9b4f0114
commit f378d2ef1b
13 changed files with 112 additions and 57 deletions

View file

@ -8,6 +8,8 @@
#include "common/assert.h"
#include "frontend/ir/microinstruction.h"
#include "frontend/ir/opcodes.h"
#include "frontend/ir/type.h"
namespace Dynarmic::IR {
@ -349,6 +351,10 @@ Type Inst::GetType() const {
return GetTypeOf(op);
}
size_t Inst::NumArgs() const {
return GetNumArgsOf(op);
}
Value Inst::GetArg(size_t index) const {
ASSERT(index < GetNumArgsOf(op));
ASSERT(!args[index].IsEmpty());