Eliminate major source of VC++ "possible loss of data" warnings.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21215 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jeff Cohen 2005-04-11 03:38:28 +00:00
parent c7c16575fe
commit 3bdfdfd10f

View File

@ -275,11 +275,11 @@ public:
}
int getFrameIndex() const {
assert(isFrameIndex() && "Wrong MachineOperand accessor");
return contents.immedVal;
return (int)contents.immedVal;
}
unsigned getConstantPoolIndex() const {
assert(isConstantPoolIndex() && "Wrong MachineOperand accessor");
return contents.immedVal;
return (unsigned)contents.immedVal;
}
GlobalValue *getGlobal() const {
assert(isGlobalAddress() && "Wrong MachineOperand accessor");