From: Alkis Evlogimenos Date: Sun, 22 Feb 2004 07:24:19 +0000 (+0000) Subject: Fix silly bug in implementation of getUseType(). Thanks Misha. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e33da36cbd138b2921057da966275a76c8792235;p=oota-llvm.git Fix silly bug in implementation of getUseType(). Thanks Misha. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11711 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/CodeGen/MachineInstr.h b/include/llvm/CodeGen/MachineInstr.h index 65d5ccae70a..7f5e6d423c3 100644 --- a/include/llvm/CodeGen/MachineInstr.h +++ b/include/llvm/CodeGen/MachineInstr.h @@ -200,7 +200,7 @@ public: /// getUseType - Returns the MachineOperandUseType of this operand. /// MOTy::UseType getUseType() const { - return isUse() ^ isDef() ? MOTy::UseAndDef : + return isUse() & isDef() ? MOTy::UseAndDef : (isUse() ? MOTy::Use : MOTy::Def); }