Add some short-hand accessors

llvm-svn: 30104
This commit is contained in:
Chris Lattner 2006-09-04 23:05:29 +00:00
parent 8386105f3f
commit 22f29396db
1 changed files with 4 additions and 0 deletions

View File

@ -111,6 +111,10 @@ public:
/// Accessors that tell you what kind of MachineOperand you're looking at.
///
bool isReg() const { return opType == MO_Register; }
bool isImm() const { return opType == MO_Immediate; }
bool isMBB() const { return opType == MO_MachineBasicBlock; }
bool isRegister() const { return opType == MO_Register; }
bool isImmediate() const { return opType == MO_Immediate; }
bool isMachineBasicBlock() const { return opType == MO_MachineBasicBlock; }