summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--llvm/include/llvm/CodeGen/Register.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/include/llvm/CodeGen/Register.h b/llvm/include/llvm/CodeGen/Register.h
index 73bca60ffcb..d1c4f471882 100644
--- a/llvm/include/llvm/CodeGen/Register.h
+++ b/llvm/include/llvm/CodeGen/Register.h
@@ -126,6 +126,9 @@ public:
bool operator!=(unsigned Other) const { return Reg != Other; }
bool operator==(int Other) const { return Reg == unsigned(Other); }
bool operator!=(int Other) const { return Reg != unsigned(Other); }
+ // MSVC requires that we explicitly declare these two as well.
+ bool operator==(MCPhysReg Other) const { return Reg == unsigned(Other); }
+ bool operator!=(MCPhysReg Other) const { return Reg != unsigned(Other); }
};
// Provide DenseMapInfo for Register
OpenPOWER on IntegriCloud